P
Peter R. Fletcher
I use Form_BeforeUpdate to check for data sanity before the User is
allowed to proceed to the next record on a form. If the sanity check
fails, the Event is cancelled and the user gets to try again! This
works fine, except if the Before_Update Event is triggered by the form
closing (for various reasons, I would like to continue to allow the
user to have access to the regular X button). If the BeforeUpdate
event is cancelled under these circumstances, you get (or have to
trap) Access's "You can't save this record at this time" error. Is
there any way of finding out that the BeforeUpdate Event was triggered
by an attempt to close the form, rather than (e.g.) an attempt to move
to a different record.
allowed to proceed to the next record on a form. If the sanity check
fails, the Event is cancelled and the user gets to try again! This
works fine, except if the Before_Update Event is triggered by the form
closing (for various reasons, I would like to continue to allow the
user to have access to the regular X button). If the BeforeUpdate
event is cancelled under these circumstances, you get (or have to
trap) Access's "You can't save this record at this time" error. Is
there any way of finding out that the BeforeUpdate Event was triggered
by an attempt to close the form, rather than (e.g.) an attempt to move
to a different record.