Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Closing all forms except 1
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00889593
Message ID:
00889598
Views:
18
Try this:
FOR lnForm = 1 TO _screen.FormCount
    IF TYPE("_screen.Forms(lnFormToClose)") == "O" .AND.;
       .NOT. ISNULL(_screen.Forms(lnFormToClose))
       IF .NOT. UPPER(_screen.Forms(lnFormToClose).Name) == "STARTUP"
          IF _screen.Forms(lnFormToClose).Baseclass == "Form"
             _screen.Forms(lnFormToClose).Release()
          ELSE
             lnFormToClose = lnFormToClose + 1
          ENDIF
       ELSE
          lnFormToClose = lnFormToClose + 1
       ENDIF
    ENDIF 
NEXT
Not tested
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