Hi,
It is possible to have dynamic arrays in Clarion but there is some limitations. The array can't be a global variable (i.e. : it has to be in a routine or a procedure.) I do it like that :
Method 1 :
I fisrt declare a global variable in my procedure
DimArray Long
Then in a routine :
DynArrayRoutine Routine
Data
DynArray LONG,DIM(DimArray)
Code
Loop i# = 1 To DimArray
DynArray[i#] = i#
message(DynArray[i#])
End
Method 2:
In the global data of the program
DimArray Long
Then in a procedure :
DynArrayPROC PROCEDURE ! DynArray LONG,DIM(DimArray)
CODE
Loop i# = 1 To DimArray
DynArray[i#] = i#
Message(DynArray[i#])
End
The dimention has to be initialised before to call the Routine or the procedure.
Hope this will help you.
Valery.