Thanks. That does it. I didn't realize there was one simple command to do this
ctda
----- Bruce M. Thompson wrote: ----
Can Access be closed programatically in VBA? I have an "Exit Application
command button on my main switchboard which closes the application but leave
Access open. Can I add some code to also Exit Access
The following command will cause Access to close the open database *and* qui
the application
DoCmd.Qui
In order to make this work with your switchboard, you may want to modify th
"HandleButtonClick" function in the code module behind the switchboard form. Yo
will need to locate the section in the "Select Case" structure that reads
Case conCmdExitApplicatio
Under that section, comment out the line that reads "CloseCurrentDatabase" an
insert, below it, the "DoCmd.Quit" command described above