Private Sub DeleteButton_Click()
If MsgBox("Do you really want to delete?", vbOKCancel, "DELETE?" = vbCancel Then Exit Sub
...
Your DELETE Procedure ...
...
End Sub
Kind regards
Mirko
--------------------------------------
>>>>>> ... I am sure, some supportissues are a matter of PEBKAC ... <<<<<
Private Sub cmdDelete_Click()
If MsgBox("Are you sure you want to delete?", _
vbYesNo Or vbQuestion Or vbDefaultButton2, _
"Delete this?") = vbYes Then
[green]
'Your Delete logic here
[/green]
End If
End Sub
This way you get the message box with Yes / No buttons, with 'No' as default, so if user just hits Enter, the 'No' will be chosen and the delete will not happen. Just for safety
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.