I want to create a message box that pops up when a control is updated. If the user selects yes, it will let them continue, if not, it will undo the changes and give another message box to say that the changes have been reversed. I started the If statement on the before update event (or would it be an On Dirty event?) below but I am doing something wrong. There isn't an error but it never lets me move away from the control if I select yes (keeps giving popup). It also doesn't undo the changes when I select no. I am sure I am doing something wrong. Does Cancel just remove the msg box? Should I do a me.undo in there?
Code:Private Sub destroy_BeforeUpdate(Cancel As Integer) If MsgBox(Prompt:="Do you really want to update?", Buttons:=vbYesNo) = vbNo Then Cancel = True MsgBox "Update Canceled" End If End Sub