Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Test for number of elements in an Array
Message
From
30/05/2006 19:05:51
 
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01126047
Message ID:
01126049
Views:
21
>>Can you test for how many elements are in an array? I need to test if the array has more than 1 element after being loaded from a table.
>
>ALEN()

This will give you the array size. However, if the array is defined (LOCAL ARRAY ...) then by default it will have at least a single row (values initialized to .F.). When ALEN(laArray,1) returns a size it will be at least one for row size but this may not be correct if no records were loaded -- you need to test the contents as well for data type.
Previous
Reply
Map
View

Click here to load this message in the networking platform