Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Message Box Reminder on close or Before Update?

0 views
Skip to first unread message

K. Boomer

unread,
Oct 7, 2008, 5:18:11 PM10/7/08
to
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.


Dirk Goldgar

unread,
Oct 7, 2008, 5:29:19 PM10/7/08
to
"K. Boomer" <KBo...@discussions.microsoft.com> wrote in message
news:52693458-E210-4FDB...@microsoft.com...

>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.


--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)

Pendragon

unread,
Oct 7, 2008, 7:16:01 PM10/7/08
to
In the On Close property of the form:

MsgBox "Verify calibration equipment has been added to database!", vbOKOnly
DoCmd.Close

boblarson

unread,
Oct 7, 2008, 11:41:01 PM10/7/08
to
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

__________________________________

Mike Painter

unread,
Oct 7, 2008, 11:56:39 PM10/7/08
to
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

K. Boomer

unread,
Oct 10, 2008, 10:15:01 AM10/10/08
to
Thanks to all for your response. The first reply from Dirk worked fine.
0 new messages