Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Top-Level form and application object
Message
 
To
23/05/1999 08:51:16
Shane Gilbert
Oklahoma State Department of Education
Norman, Oklahoma, United States
General information
Forum:
Visual FoxPro
Category:
Classes - VCX
Miscellaneous
Thread ID:
00221876
Message ID:
00221933
Views:
13
>I have used the VFP 5.0 wizard to create an "application frame only." I would like to completely hide the Foxpro screen, so I thought I would create my main form as a top-level form. I am having problems getting the Shutdown to work right. When I close the form the application object doesn't get released, and if I put a QUIT in the Unload event of the form (which would call the application object's OnShutdown) I get a message about can't clear object in use. I can leave out the clear all but then the application is still active in memory. What am I missing?

In addition to what John says, I can add:

1) There is no such thing as ON SHUTDOWN or QUIT for a top-level, since those are only relevant to the main vfp screen.

2) I usually close a TL with at least these two lines of code in the TL Queryunload:

Thisform.Release
Clear Events

If you have Exit from form, menu, or toolbar, you can just call the TL Queryunload to do the closing business, and maybe have other code to decide if closing is okay, and clean a few other things up there, as well...
The Anonymous Bureaucrat,
and frankly, quite content not to be
a member of either major US political party.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform