AfterUpdate event of Form

  • Thread starter Thread starter Ladislav P via AccessMonster.com
  • Start date Start date
L

Ladislav P via AccessMonster.com

Hi,
I need save new/updated record but just after when user of database decides
to save it. I think it muss be done with a pop up window with Question "Do
you will save changes/new record?" with 2 Buttons "Yes" or "Not".
Can someone help me??

Thanks in adwance
 
try the following in the form's BeforeUpdate event, as

Private Sub Form_BeforeUpdate(Cancel As Integer)

If MsgBox("Do you want to save changes/new record?", _
vbYesNo + vbDefaultButton2) = vbNo Then
Cancel = True
Me.Undo
End If

End Sub

hth
 
Your help is excellent - it work without one error.

Thanks, thanks, thanks ...


L.P.
try the following in the form's BeforeUpdate event, as

Private Sub Form_BeforeUpdate(Cancel As Integer)

If MsgBox("Do you want to save changes/new record?", _
vbYesNo + vbDefaultButton2) = vbNo Then
Cancel = True
Me.Undo
End If

End Sub

hth
Hi,
I need save new/updated record but just after when user of database decides
[quoted text clipped - 3 lines]
Thanks in adwance
 
you're welcome :)


Ladislav P via AccessMonster.com said:
Your help is excellent - it work without one error.

Thanks, thanks, thanks ...


L.P.
try the following in the form's BeforeUpdate event, as

Private Sub Form_BeforeUpdate(Cancel As Integer)

If MsgBox("Do you want to save changes/new record?", _
vbYesNo + vbDefaultButton2) = vbNo Then
Cancel = True
Me.Undo
End If

End Sub

hth
Hi,
I need save new/updated record but just after when user of database
decides
[quoted text clipped - 3 lines]
Thanks in adwance

--
L.Petko


Message posted via AccessMonster.com
 
Back
Top