Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Equivalent of Nothing in VB
Message
From
07/06/2005 18:16:13
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
07/06/2005 18:10:22
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9
Miscellaneous
Thread ID:
01021162
Message ID:
01021163
Views:
19
>I am converting code that was for VB6 to VFP and have run into the use of the "Nothing" keyword. From the help:
>
>The Nothing keyword in VBScript is used to disassociate an object variable from any actual object. Use the Set statement to assign Nothing to an object variable. For example:
>
>Set MyObject = Nothing
>
>Is there an equivalent in VFP 9? This appears to be a reference to an object variable that is null. I have tried to use null, but this gives an error of improper type.
>
>Any suggestions? Thanks.

I have seen NULL used in cases like this. I don't understand why you would get an error message.

Perhaps there is a problem in the Destroy() Event, for example. See if you also get an error message if you release the object variable: RELEASE MYOBJECT
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Reply
Map
View

Click here to load this message in the networking platform