My Switchboard won't exit!

Doctor Kronenbo

Registered User.
Local time
Today, 10:10
Joined
Oct 28, 2004
Messages
28
I've created a new database using the standard Switchboard function. However, when I use the Exit Application command the database closes but MS Access stays open. It's a minor problem but infuriating, especially as I've never encountered this problem before and everything I try won't fix it. Any ideas?
 
Should use DoCmd.Quit, I think...

But do you have any form-based BeforeUpdate code that involves the possibility that a particular situation could cause the code to signal a Cancel?

Look through any forms or reports in the class modules for exit-type events that could cancel your form-close event. (You should know if you wrote any.) One of them might be the cause of this problem. In which case the fix is to tighten up the code to allow the exit to proceed. This problem is most common on forms that are both minimized and hidden. (Out of sight, out of mind...)
 
Second note: Sometimes our browsers go nuts and sometimes we get a little lax. Please do not double-post. You can delete one of the posts by trying to edit it. One of the options is to delete the post.
 
I've tried integrating the DoCmd.Quit and Application.Quit commands into the switchboard code but neither has been successful. I don't have any BeforeUpdate code anywhere in the project. I do have an Exit Application button on the main form and that works fine. Could this interfere with the Exit command on the switchboard?

Apologies for double post. The internet connection in my office is atrocious and it looked like it hadn't posted my original post as it frequently does with many forums. I'll delete it ASAP.
 
Problem solved. I sorted it by creating an Exit Macro and calling it from the Switchboard. Works fine now. Thanks for your help.
 
I make several modifications to the switchboard form and that is one of them:

Code:
        Case conCmdExitApplication
            
            '''''CloseCurrentDatabase  -- leaves Access open- replace with the following
                        
            Application.Quit acQuitSaveAll
 

Users who are viewing this thread

Back
Top Bottom