How about:
Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
If CloseMode = vbFormControlMenu Then
Beep
'msgbox "doesn't work"
Cancel = True
End If
End Sub
cwwolfdog wrote:
I can't figure out how to prevent someone from clicking the close (X) icon on
a user form. I have a cancel button which is what I want them to have to use.
thanks
--
Dave Peterson
|