iOS Question Variable Name

Discussion in 'iOS Questions' started by Claude Brun, May 9, 2019.

  1. Claude Brun

    Claude Brun Member Licensed User

    Hello, I have a table with items xx1, xx2, xx3 ...
    I have to fill all these items with the same value. Xx01 = "x", xx02 = "x" ...
    but I would like to make a loop from 1 to n, build the name of the variable "xx" & i
    But I do not know how to use this variable name to load the value

    Thank

    PS : excuse my poor english
     
  2. klaus

    klaus Expert Licensed User

    You cannot!
    You could use an Array, or use a List.
     
  3. Claude Brun

    Claude Brun Member Licensed User

    aie aie,

    Thank
     
  4. Star-Dust

    Star-Dust Expert Licensed User

    I would use the map

    Code:
    Dim M As Map
     
    M.Initialize
     
    For I=1 To 10
         M.Put(
    "xxx" & I, "X")
    Next

    Log(M.Get("xxx1"))
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice