Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Arrays & SQL
Message
 
To
14/08/1996 09:12:11
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00005634
Message ID:
00005701
Views:
32
>>>>I'm creating a class with a property (array) that holds the result of a query. I always declare my variables before I use them. And I want to SELECT ... INTO ARRAY ... The problem is that I don't know the size of the query.
>>>>I don't like this... Do you?
>>>
>>>I think that in this case u will be better off by not decalring the array
>>>before the SELECT- SQL
>>>
>>>Arnon
>>
>>That's OK, but how to make it a property ? By declaring it twice, and then
>>moving all the data into the property, and then releasing the array created by the SQL SELECT ? Nah! I don't like it, should I?
>>
>>Thanx
>sorry - the solution is very simple
>u don't have to do anything special
>
>create an array property in the form (e.g. gaMyArray[1])
>and in the select just do
>SELECT myfield ... into array thisform.gaMyArray
>
>the array will redimention
>
>Arnon

for some reason, i always forget the 'thisform.'... it's easy enough to debug, but not much help here....
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform