B
bob
All of a sudden the code below fails to compile and complains that the
UNDO method is not found......This happens on two different PCs.
Ironically, the code works properly - but it just won't compile.
References are fine: no complaints re: missing references.
Anybody got any idea what is going on? Thanks!
Bob Galway
Private Sub Form_BeforeUpdate(Cancel As Integer)
On Error GoTo Err_Form_BeforeUpdate
Dim strTemp As String
If Me.Dirty = True Then
strTemp = "Data has changed. Save Changes?"
If MsgBox(strTemp, vbYesNo + vbQuestion, _
"Please Confirm") = vbNo Then
'User has chosen not to save data:
Me.Undo
End If
End If
Exit_Form_BeforeUpdate:
Exit Sub
Err_Form_BeforeUpdate:
MsgBox Err.Description & "---" & Err.Number
Resume Exit_Form_BeforeUpdate
End Sub
UNDO method is not found......This happens on two different PCs.
Ironically, the code works properly - but it just won't compile.
References are fine: no complaints re: missing references.
Anybody got any idea what is going on? Thanks!
Bob Galway
Private Sub Form_BeforeUpdate(Cancel As Integer)
On Error GoTo Err_Form_BeforeUpdate
Dim strTemp As String
If Me.Dirty = True Then
strTemp = "Data has changed. Save Changes?"
If MsgBox(strTemp, vbYesNo + vbQuestion, _
"Please Confirm") = vbNo Then
'User has chosen not to save data:
Me.Undo
End If
End If
Exit_Form_BeforeUpdate:
Exit Sub
Err_Form_BeforeUpdate:
MsgBox Err.Description & "---" & Err.Number
Resume Exit_Form_BeforeUpdate
End Sub