Wayne,
This may work if the command does not rely on data in the form that is being
closed.
I am trying to do something quite similar: When the DB closes, I trigger a
Query in the "OnClose" event of a form that is always open, which records the
time the DB was closed and the ID of the user that closed it. The user's ID
is in a control on the form being closed.
If I close the form with the black X on the FORM, it works perfectly.
However, if I close the whole DB by clicking the ACCESS black X (closing the
whole DB at once), the query cannot find the data in the control in the
form...as if the form is already closed.
When Access is closed, the OnClose action of the forms runs, but the data on
the form isn't available.
Any solutions?
Brossyg