S
Sammie
I'm Using Access 2000 on a form to add a new record to a table. Please help
me figure out why records are being deleted with the following code:
Private Sub Form_BeforeUpdate(Cancel As Integer)
Dim strMessage As String
Dim intOptions As Integer
Dim bytChoice As Byte
If IsNull(Status) Then
strMessage = "You didn't indicate what you are waiting for. Do you
want to do this now?"
intOptions = vbQuestion + vbYesNo
bytChoice = MsgBox(strMessage, intOptions)
If bytChoice = vbYes Then
Cancel = True
Status.SetFocus
End If
End If
End Sub
Records get deleted when I say yes. I think if I say no, the
"Form_beforeupdate" procedure ends and I don't loose records, but I'm not
positive. Allow deletions on this form is set to "no".
Thank you.
Sammie
me figure out why records are being deleted with the following code:
Private Sub Form_BeforeUpdate(Cancel As Integer)
Dim strMessage As String
Dim intOptions As Integer
Dim bytChoice As Byte
If IsNull(Status) Then
strMessage = "You didn't indicate what you are waiting for. Do you
want to do this now?"
intOptions = vbQuestion + vbYesNo
bytChoice = MsgBox(strMessage, intOptions)
If bytChoice = vbYes Then
Cancel = True
Status.SetFocus
End If
End If
End Sub
Records get deleted when I say yes. I think if I say no, the
"Form_beforeupdate" procedure ends and I don't loose records, but I'm not
positive. Allow deletions on this form is set to "no".
Thank you.
Sammie