Application.quit

MarionD

Registered User.
Local time
Today, 21:48
Joined
Oct 10, 2000
Messages
425
Help- I need somebody!!

For some reason my Application.quit acSaveall in me access application closes the DB, but leaves the access.exe running ! When I try to to log on to the DB again - it seems to open - but somehow hidden! I have to go into the task manager and end the access.exe, then I can logon to my db with no problem.
access.exe seems to remain active and cannot be closed just by clicking on the X. There is also no menu bar - just a gray screen. I can only end the process in the task manager.

I have never had this happen before? Anyone have an Idea?

Marion
 
Code:
Help- I need somebody!!

For some reason my Application.quit acSaveall in me access application closes the DB, but leaves the access.exe running ! When I try to to log on to the DB again - it seems to open - but somehow hidden! I have to go into the task manager and end the access.exe, then I can logon to my db with no problem.
access.exe seems to remain active and cannot be closed just by clicking on the X. There is also no menu bar - just a gray screen. I can only end the process in the task manager.

I have never had this happen before? Anyone have an Idea?

Marion

Typically this happens when an object variable is not set to nothing (i.e. set db = nothing). If you have the time go back through the code and see if any objects are being created that are not being destroyed.

Or if you don't have the time or patience for that try this code.

Code:
Declare Function DestroyWindow Lib "user32" (ByVal hwnd As Long) As Long

Function CloseAccess()
Call DestroyWindow(Application.hWndAccessApp)
End Function
 
Thanks so much for the answers. The problem was as you say, a variable that was not set to nothing. It took time and patience, but I found it. Thanks for the code anyway... a handy quick fix to know !
 

Users who are viewing this thread

Back
Top Bottom