Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Syntax, Scope or Stupidity?
Message
 
To
28/12/2010 11:33:46
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Miscellaneous
Thread ID:
01494008
Message ID:
01494009
Views:
98
>Re: Thread ID: 1473802
>I have 2 modeless forms open and I run the following code:
>
>Both appear as open forms in the messagebox below, but I cannot programatically close the one called OrderEntry_Scx.
>
>Can you help? Thank you!
>
>
>
>	FOR EACH loForm In _Screen.Forms
>		=Messagebox('Here is the form: ' + loForm.Name)
>		 IF loForm.caption = 'OrderEntry_Scx'
>			 	*!* loForm.Release()
>			 	*!* loForm.Name.Release()
>			 	*!* OrderEntry_Scx.Release()
>			 	*!* loForm.Release 
>			 	*!* loForm.Name.Release 
>			 	*!* OrderEntry_Scx.Release 
>		 ENDIF
>	NEXT 
>
I really doubt that the Caption of the form is OrderEntry_Scx. Maybe this is the Name of the form, but not the caption.
...
     =Messagebox('Here is the form: ' + loForm.Name)
****  IF loForm.caption = 'OrderEntry_Scx'
     IF loForm.Name = 'OrderEntry_Scx' && Name not Caption
...
:-)
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Reply
Map
View

Click here to load this message in the networking platform