Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is there a function to check whether a field exist in tb
Message
 
 
To
08/03/2002 11:10:21
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00629929
Message ID:
00630259
Views:
21
>OOPS ...
>Correction: varType(myfield) correctly returns a U when 'myfield' field is non existent.

This is not a reliable check, because you may have variable myField defined...
vartype(MyTable.myField) would generate an error, as Marcia pointed out... So, type('MyTable.myField') is the correct solution if your table is a free table. Otherwise INDBC() function could be used instead.
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform