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

I have fallen in love with access a

Status
Not open for further replies.

AccessNovice

Programmer
Feb 7, 2001
24
US
I have fallen in love with access after using it just a month. Wish I were a pro. I built a table with log on and log off fields. The log on field works but not the log off field. When a user closes that access 95 database/or entire db, the time won't show on my Operator table. Would an UPDATE Operator(LoggedOffTime)...macro help?....have a table Operator with fields LoggedOffTime etc...logging off on WonderWareInTouch shows on table...any creative ideas/help appreciated
 
All you should really need is one field True/False if all you really need to monitor is if the user is...on or off.
If you are opening the database through a switchboard or main form build 2 queries: 1 update query to update your CurrentUser "logged" to true. add this query to the On Load event of this form. The second query is the reverse of the first and should be fired from the Unload event of your main form. Surround both queries with DoCmd.Setwarnings False and then True. Be forewarned: If you have a system crash these events may not fire so you would have to be able to access the table by whatever means to clean up any incorrect records. If you need further explanation or examples contact me. ghubbell@total.net Nice to see you're enjoying Access!
 
The solution above should work if you quit the application from the same form each time. You must ensure that users only have that method to exit the application. Also remember that when a user hangs the system they will CTL-ALT-DEL out of Access and you surely will have incomplete records.

Steve King
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top