Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Disabling the "X" Close Application button in Access 2003 1

Status
Not open for further replies.

BobChesh

Technical User
Dec 13, 2001
39
0
0
GB
How do I disable the "X" Close Application button in Access 2003?

I am trying to see who is logged on the the database (found that through thread 705-846343) and there is a link to another thread, but that is broken.

I need to prevent users from closing the application using the "X" and forcing them to use the EXIT button which then deletes them from the Users Login in table.
 
The X close button for the actual access application or for a form that is being displayed as the application?

HarleyQuinn
---------------------------------
Carter, hand me my thinking grenades!

You can hang outside in the sun all day tossing a ball around, or you can sit at your computer and do something that matters. - Eric Cartman

Get the most out of Tek-Tips, read FAQ222-2244: How to get the best answers before posting.

 
HarleyQuinn

I am looking to disable the application, since I have an "exit" button which closes the application (Application.Quit), after it deletes that user from the UserTbl created when the application is opened, if you see what I mean.
 
A common way is to have an hidden startup form and a global boolean variable.
The "exit" button Click event procedure set the boolean to True and the Unload event procedure of the startup form sets the Cancel parameter to True unless the global boolean is true.

Hope This Helps, PH.
FAQ219-2884
FAQ181-2886
 
As it's the application I was going to suggest the API route, but AceMan beat me to it...

HarleyQuinn
---------------------------------
Carter, hand me my thinking grenades!

You can hang outside in the sun all day tossing a ball around, or you can sit at your computer and do something that matters. - Eric Cartman

Get the most out of Tek-Tips, read FAQ222-2244: How to get the best answers before posting.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top