Quit app when last window is closed?

bonedoc

Well-known member
Joined
May 4, 2006
Messages
112
Programming Experience
Beginner
In the app properties, I selected to have the app quit when the final window is closed. Well, the app is still shutting down completely when I close the main form. Does anyone know what would cause this?

I tried to create a module and use Sub Main(). This did not seem to work too well either. Any ideas.
 
in VS 2005 you can set it to keep the program running until all forms are closed, but in 2002 and 2003 that's not the case, in these situations i start from Sub Main and i use a Do Until loop until a boolean (blnExitApp) equals True

by doing it this way i can allow the user to open numerous forms, but keeping track of whether the app should exit or not depending on that boolean i could write a simple app to demonstrate if needed (it wont have the kind of flexibility that you're expecting, but it works)
 
Back
Top