G
Guest
Hi,
I have this code in the form and it is not allowed to save anything within
the form unless it has been saved. But my if msgbox isn't working.
Can anyone help my cause? Thx. Sarita
Private Sub Form_BeforeUpdate(Cancel As Integer)
If MsgBox("do you want to save?") ,vbYesNo = vbYes
Else
Cancel = True
MsgBox "Update was cancelled", vbOKOnly
End If
End Sub
I have this code in the form and it is not allowed to save anything within
the form unless it has been saved. But my if msgbox isn't working.
Can anyone help my cause? Thx. Sarita
Private Sub Form_BeforeUpdate(Cancel As Integer)
If MsgBox("do you want to save?") ,vbYesNo = vbYes
Else
Cancel = True
MsgBox "Update was cancelled", vbOKOnly
End If
End Sub