Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to check if a variable is an array
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00524483
Message ID:
00524485
Views:
12
>I have some code which collects an array as a parameter. Some rogue piece of code is passing something else. The code copes when run via fox but dies through the app.
>
>The build app function tells me (through errors) that it's there but not where to find it.
>
>How do I check if the parameter is an array and suspend if it's not? Type() doesn't work.
>
>Sarah

There is a sample code that shows how to check if parameter is an array
Function Myfunction
Lparameter taMyarray
IF Type("taMyarray[1]") = "U"
    * It's not array
    Wait Wind "Not Array"
ELSE
    * it's array
    Wait Wind "Array"
ENDIF
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform