M
M Skabialka
I have a front-end database I distribute to several people. We all use
Access 2000.
On one form there is the ability to delete a record using a command button.
The button code is this:
Private Sub DeleteTask_Click()
On Error GoTo Err_DeleteTask_Click
If MsgBox("Are you sure you want to delete this task?", vbYesNo,
"Warning!") = 6 Then
DoCmd.SetWarnings False
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70
DoCmd.SetWarnings True
End If
Exit_DeleteTask_Click:
Exit Sub
Err_DeleteTask_Click:
MsgBox Err.Description
Resume Exit_DeleteTask_Click
End Sub
Sometimes for some people, when they click this button they get an error
message (which they haven't written down) that refers to "|" as part of the
error. However, after they click OK (or Yes?) the massage goes away and the
record gets deleted.
I cannot duplicate the error through adding then deleting tasks, though they
have seen it on two PCs. Records are seldom deleted so am not sure how to
find out what the error is.
Thanks,
Mich
Access 2000.
On one form there is the ability to delete a record using a command button.
The button code is this:
Private Sub DeleteTask_Click()
On Error GoTo Err_DeleteTask_Click
If MsgBox("Are you sure you want to delete this task?", vbYesNo,
"Warning!") = 6 Then
DoCmd.SetWarnings False
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70
DoCmd.SetWarnings True
End If
Exit_DeleteTask_Click:
Exit Sub
Err_DeleteTask_Click:
MsgBox Err.Description
Resume Exit_DeleteTask_Click
End Sub
Sometimes for some people, when they click this button they get an error
message (which they haven't written down) that refers to "|" as part of the
error. However, after they click OK (or Yes?) the massage goes away and the
record gets deleted.
I cannot duplicate the error through adding then deleting tasks, though they
have seen it on two PCs. Records are seldom deleted so am not sure how to
find out what the error is.
Thanks,
Mich