Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Multiple forms/formsets
Message
From
02/08/1999 18:50:15
 
 
To
02/08/1999 15:29:25
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00248756
Message ID:
00249057
Views:
23
>>>I would like to find a way to close forms or formsets beyond the one that the user is currently working on. Users often open another menu choice without closing the first. This can then become several forms deep. By using formcount and _screen properties, I can determine that a previous form is still open, but I am having a hard time determing if it is a form or part of a formset, which I think I need to know to release it. Perhaps there is some code to close the last form/formset as the next one is opening.
>>
>>Your interface sounds a little awkward, but anyway, something like:
>>
>>if type('_screen.activeform.parent.class') = 'C'
>>
>>should distinguish between formset/form...
>
>Or, more precisely if type('_screen.forms[i].parent.name')="C" and _screen.forms[i].parent.baseclass="Formset"

I used type('_screen.forms(n).parent.class') = "C" for _screen.formcount > thisformset.formcount. It works as the type equals "C" only in the case of a formset, since forms have no parent, and type is something, but not "C". The above would also determine the same point, that a parent to the given form exists.
Thanks for the input. Type is a new property to me, but seems pretty useful.

PB
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform