deanl33069
Board Regular
- Joined
- May 2, 2019
- Messages
- 120
how do i force a command button to be pushed before exit.
What do you mean by "exit"? Close the Excel Application or just close a workbook??how do i force a command button to be pushed before exit.
Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer)
If CloseMode = vbFormControlMenu Then
Cancel = True
MsgBox "Please use the ""Close"" button.", vbCritical, "Illegal Exit"
End If
End Sub