Trapping Access Closing down.

J

JH

Hi,

Some of my users seem to hit the close button (the X at top right of the
screen) for the Access application instead of for the form they are viewing.
So they get chucked out back to windows and have to start over again!

Is there a way of trapping this so that I can ask the if they are sure they
want to quit access first?
 
D

Douglas J. Steele

Make sure that you always have a form open (it can be hidden).

Put your prompt in the form's Unload event. If they don't want to quit, set
Cancel = True, and the form won't be unloaded, thus keeping Access alive.
 
Top