Re: Ensuring a nice clean application quit experience
- From: "paii, Ron" <paii@xxxxxxxxxxxxxx>
- Date: Wed, 2 May 2007 12:56:13 -0500
<teddysnips@xxxxxxxxxxx> wrote in message
news:1178117322.372801.193980@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
This is sort of an addendum to my previous post entitled: "Restrict FEAs Scott said, there is no 100% reliable way to delete the record on exit.
application to one user at a time".
My preferred design is to have a table with a single row that contains
the network name of the person currently connected to the database.
The existence of the row will serve a) to allow the system to bump any
other user who wishes to connect, and b) to inform such users of the
name of the currently logged-on user.
However, at the end of the session, it is VITAL that the row is
deleted from the table, so that the next time someone tries to
connect, if there is no-one connected, they can then take control of
the system.
Obviously, I can have a button on a switchboard somewhere called
"Exit" and do the clean-up just prior to Application.Quit.
However, is there any way of trapping the user pressing the
"Close" (X) button, or ALT+F4, or whatever, and ensuring that clean-up
is always achieved?
Thanks as usual
Edward
Why not create a table in the back-end with one record. On application
startup, check if the record is locked, if it is exit, if it is not lock it.
The record lock should release when Access shuts down. Even if Access
crashes, Windows would normally release the lock and delete the .LDB file.
.
- References:
- Ensuring a nice clean application quit experience
- From: teddysnips
- Ensuring a nice clean application quit experience
- Prev by Date: Re: date default settings on Access
- Next by Date: Re: linking images in a split database
- Previous by thread: Re: Ensuring a nice clean application quit experience
- Next by thread: Query summarize data
- Index(es):