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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Auto close a database after 5 minutes

Status
Not open for further replies.

rrhandle

Programmer
Dec 26, 2001
193
US
Is there a way to force Access to close by itself after it has been open for 5 minutes?

The user forgets to close things on their pc, and others use the user's pc. When the user is viewing the HR database, they do not want others to see this information if they, the user, walks away and forgets to log-out. Ya, I know, tell the user to take a memory class. Unfortunately, the user calls the shots.

 
It would be cruel to shut down without warning so I think you need two forms with timers.

One timer on a hidden form which is reset every time that the user does something. If that timer runs for 5 minutes without seeing any activity from the user then it opens the second form to warn that closedown is imminent.

This warning form has a timer which will close Access unless the user re-enters their ID and password within 20 seconds.

Geoff Franklin
 
Thats a cool article rrhandle. I'll have to see if I can build that into some existing DB's I have.

Are you looking for something that maybe looks at the active control or active form and if it doesn't change, hence the user has walked away, save and close the DB after 5 min??

I found something like that and use it in ALL of my DB's and I'll dig it out if you are interested.
 
Thanks, jadams0173.

I used the article to cobble together something myself that was much simplier. Warns the user that the db will close in 1 minute unless they click the "OK" button.

Yes, that is a very good article.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top