Parameter box pops up on application quit

Kregg

Registered User.
Local time
Today, 09:19
Joined
Jul 8, 2013
Messages
41
When my database application is closed a parameter box pops up asking for parameter from text16 but only if the Navigation Pane is hidden.

Some information:

The application starts with a login screen that has a hidden text box (text16) that allows me to limit what users can access throughout the database by setting it as the query criteria.

If a form is open that is gathering its data from one of these querys and you try to close the application the parameter box opens which is simply annoying for my users who do not know about access.

The interesting thing about this is that if I unhide the Navigation Pane and close the application with one of these forms open it closes fine with no parameter box pop up.

The goal is to have the Navigation Pane hidden and the parameter box not pop up.

Any ideas on how to fix this issue?

Added information if the navigation pane is hidden I can use a command button with a macro that closes all open forms then quits application and this does not cause the parameter box to pop up.

So another fix for my problem would be to disable the "X" close button at the top right of the application.
 
Last edited:
Close the query before you close the login form.
 
Thanks for the response Pat. am I able to attach VBA code to the close button (red X) that closes all forms before application is quit?

I have created a Logoff button that effectively does this and it works with the Navigation Pane hidden. The problem is my users are so used to clicking the red X that they forget to click the Logoff and since they do not know computers that well they get confused and think they broke something.

Another piece of information that I forgot to mention. The Login Screen is stays open but is hidden once login is initiated so users would not be able to simply close that form.
 
Most of my apps have a hidden form which is the first to open and the last to close. Access doesn't provide any event that can be used to trap "close the database" so you have to improvise. On my login form, after a successful login, I open the switchboard but instead of closing the login form, I just hide it - Me.Visible = False.

Then in the Unload event of this form, I can do what ever I need to before the database actually closes.
 
I have my login screen set up the same way Pat. I was not aware of the unload event so I used a different work around. I created a log off button on all forms and disabled the red X as well as the X to close any forms so users wouldn't get stuck in a place that they couldn't close the database. After I disabled the X to close database and forms I tested it with the Navigation Pane hidden and it worked perfectly!
 
How do I mark this thread as solved? First thread...
 
Go to the ThreadTools dropdown at the top of the thread - there's an option in there to mark it as Solved :)
 
The option to mark a thread as Solved is under thread tools,

attachment.php
 

Users who are viewing this thread

Back
Top Bottom