>Hi
>
>How can I close all the forms in _Screen.
>
>I have tried:
>
>FOR x = 1 TO _Screen.FormCount
>_Screen.FOrms(x).Release()
>ENDFOR
>
>But this gives me problems, because when a form is closed, the formcount is reduced and this seems to cause problems.
>
>Any ideas on how this should be done correctly?
>
>Thanks
>Kev
Kevin,
You have to go in reverse order.
lnCount = _Screen.FormCount
FOR x = lnCount TO 1 STEP -1
_Screen.Forms(x).Release()
ENDFOR
Jens Erik