Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How To Release An Object
Message
 
 
To
08/10/1998 19:53:07
Dave Nantais
Light speed database solutions
Ontario, Canada
General information
Forum:
Visual FoxPro
Category:
Object Oriented Programming
Miscellaneous
Thread ID:
00145291
Message ID:
00145298
Views:
33
Dave,

The object no longer exists, but the memvar that referenced it still does, it has TYPE of O with a .null. value. Most of the time when creating objects you just let the memvar scope deal with the lifetime fo the object. If you do commands from the command window you are creating PUBLIC memvars, doing the same thing in code will create private (by default) so the go out of scope when the code ends.

>I created an object using CREATEOBJECT and placed a method in
>the object called "RELEASE".
>
>The method had only one statement ...
>
>"RELASE THIS"
>
>Later on in the procedure i attempt
>
>OBJECTNAME.RELEASE
>
>but the variable still exists in memory.
>
>As a work around i simply do a RELEASE OBJECTNAME
>and this works fine.
>
>However isnt the RELEASE method supposed to work as well?
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Previous
Reply
Map
View

Click here to load this message in the networking platform