Message Box Reminder on close or Before Update?

  • Thread starter Thread starter K. Boomer
  • Start date Start date
K

K. Boomer

I would like a message box to appear once the user has filled out the form
and wants to close it or move on to the next record.

It's a simple reminder message and does not require any input, nor does it
rely on data in any other field on the form.

"Verify calibration equipment has been added to database!" Then the form
closes after this appears.

Thanks in advance for your assistance.
 
K. Boomer said:
I would like a message box to appear once the user has filled out the form
and wants to close it or move on to the next record.

It's a simple reminder message and does not require any input, nor does it
rely on data in any other field on the form.

"Verify calibration equipment has been added to database!" Then the form
closes after this appears.


If the user doesn't have to confirm the update, it makes sense to put such a
message in the form's AfterUpdate event:

Private Sub Form_AfterUpdate()

MsgBox ""Verify calibration equipment has been added to database!"

End Sub

The message will be displayed any time a record is saved, regardless of
whether the save occurred because the user moved to a new record or because
they closed the form. It will not be displayed if nothing on the form was
modified (by the user or by your code) so that no record will be updated or
added.
 
In the On Close property of the form:

MsgBox "Verify calibration equipment has been added to database!", vbOKOnly
DoCmd.Close
 
No, Pendragon - Dirk's response is correct. You can't put it in the form's
close event because the user may not close the form. They may just go on to
the next record. So, the form's After Update event makes sense for this.
--
Bob Larson
Access MVP
Free Tutorials and Samples at http://www.btabdevelopment.com

__________________________________
 
If they have to do this I would think that the messasge should be placed in
the field(s) where the calabration is added and the form kept open until
then
 
Back
Top