TYPE at
a
b[0][0]
ENDTYPE
GLOBAL c AS at
REDIM c.b[10][10]
Is this an OK way to store a 2 dimensional array variable name in a type? The reason I ask, is that if I use a 1 dimensional array I would use the code...
TYPE at
a
b[]
ENDTYPE
Notice the lack of '0', but if I try...
TYPE at
a
b[][]
ENDTYPE
I get a syntax error.
I don't mind using the
If you want it pre-sized, use:
TYPE Ttyp
array[5][6]
ENDTYPE
Otherwise just array[].
You can DIM any array with any dimensions (up tp 4).
Like:
LOCAL a[]
DIM a[5]
DIM a[13][12]
So for a 2 dimensional array that is not DIMed yet I just put in ...
TYPE at
b[]
ENDTYPE
GLOBAL c AS at
REDIM c.b[10][10]
...Just tried this, it seems to work fine.