Announcement

Collapse
No announcement yet.

Structure

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Structure

    Is there anything similar to structure or class or arraylist in EFS? I have created a comma separated set of values and I am passing it as a global variable. On the receiving end I separate each one and I put it into an array, however referring to each array element using element number is somewhat confusing, I am looking for an easier way to refer to each element of the array possibly using a name instead of a number, do you have any recommendations?

    thanks

    Behzad G.
    Tony Gof

  • #2
    the only practical way i am aware of to keep names is to simply make a variable for each piece of data, i assume youre not using loop statements since you couldnt possibly hope to call different names through a loop without using index numbers, but that would defeat the purpose since what you are trying to do is not use index numbers.
    so either make a variable for each peice of data, or make a legend so you can keep the index numbers straight.

    unless of course you are trying to make 2D arrays. Array[3, 43] can get really confusing, but you could simply break it up into single dimensional arrays if you must, ie:

    HighValues[100]
    LowValues[100]
    OpenValues[100]
    CloseValues[100]

    instead of a 2D array like this

    BarValues[4, 100]



    i hope that helped, without more information i dont know what else i could say

    Comment


    • #3
      Re: Structure

      Hi Behzad,

      Check out this link, you can use strings to define array elements similar to the manner in which kalzenith described how to use the 2D arrays.
      http://www.hunlock.com/blogs/Masteri...ascript_Arrays. In effect you are creating a named object reference an array.

      I had this link in my fileshare in this folder JavaScript Links where there are other related links. hope this helps.


      Originally posted by Behzadgof
      Is there anything similar to structure or class or arraylist in EFS? I have created a comma separated set of values and I am passing it as a global variable. On the receiving end I separate each one and I put it into an array, however referring to each array element using element number is somewhat confusing, I am looking for an easier way to refer to each element of the array possibly using a name instead of a number, do you have any recommendations?

      thanks

      Behzad G.

      Comment


      • #4
        structure

        This is a great link.

        Thanks

        Behzad.
        Tony Gof

        Comment


        • #5
          Re: structure

          Hi Behzad,

          Good to hear, you are most welcome.

          Originally posted by Behzadgof
          This is a great link.

          Thanks

          Behzad.

          Comment

          Working...
          X