Prompt user when editing records

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How can I get Access to prompt users before changes to existing records are made to prevent unintentional changes ?
 
Use the BeforeUpdate event of the *form*:

Private Sub Form_BeforeUpdate(Cancel As Integer)
If MsgBox("Save changes?", vbOkCancel) <> vbOk Then
Cancel = True
'Me.Undo
End If
End Sub

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

David said:
How can I get Access to prompt users before changes to existing records
are made to prevent unintentional changes ?
 
Many thanks Allen, it did the trick. I'm surprised how complex it is, I could never have dreamed it up.

best regards,

David
 
Back
Top