Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Removeobject does not remove
Message
 
To
10/01/2012 13:30:56
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9
Miscellaneous
Thread ID:
01532655
Message ID:
01532663
Views:
57
>i have the following code to remove a container object when not needed anymore:
>
>IF PEMSTATUS(THISFORM, [cntEmployer], 5)
>	thisform.cntEmployer.VISIBLE=.f.
>	thisform.RemoveObject([cntEmployer])
>ENDIF 
>
>
>no error but the object deas not get removed.
>any thoughts?
>
>Thanks
>
>
>Peter

What debug said?
Did cntEmployer is a member of thisform or any other container?
How about to use quotes instead of square brackets?
SET ASSERT ON
ASSERT PEMSTATUS(THISFORM, "cntEmployer", 5) MESSAGE "cntEmployer did not exists"

IF PEMSTATUS(THISFORM, "cntEmployer", 5)
   thisform.cntEmployer.VISIBLE=.f.
   thisform.RemoveObject([cntEmployer])
ENDIF
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform