Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
_Screen object
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
Miscellaneous
Thread ID:
00392079
Message ID:
00392191
Views:
10
>Works great! Thanks! But why should that make a difference (using the reverse loop)?

MIchael,

Here's why;

As your loop starts there are 3 forms, i starts as 1 and the first form is released. i increments to 2 and the formcount drops to 2. Second time i is 2 and the second form is released. i increments to 3 and formcount drops to 1. Third time i is 3 and there is only one form so _screen.Froms(3) is not a form. Working backwards is one way and another is this;
FOR i = 1 TO _screen.formcount
   _screen.forms(1).Release()
ENDFOR
and another;
FOR EACH oForm in _Screen.forms
   oForm.Release()
ENDFOR
Previous
Reply
Map
View

Click here to load this message in the networking platform