How can i detect if the 'X' (Close button) in the right corner of the window have been clicked on??
------------------
Yours sincierly
CyberCarsten
http://home18.inet.tele.dk/cyber/
[email protected]
Printable View
How can i detect if the 'X' (Close button) in the right corner of the window have been clicked on??
------------------
Yours sincierly
CyberCarsten
http://home18.inet.tele.dk/cyber/
[email protected]
Use the unload event of the form. For example, if you didn't want the form to close when that X was pressed:
-----------
Private Sub Form_Unload(Cancel As Integer)
Cancel = True
End Sub
-----------
The check should be done in the QueryUnload event rather than the Unload event. See my answer to a previous question.
------------------
Marty
COGITO EGGO SUM
I think; therefore I am a waffle.