How to hide the closing X on a windows form?
-
I have a fire alert application that for no reason what so ever should be closed, this you can fix by adding the following in the Form_Closing event e.Cancel = true; But how do I hide the closing X icon? :confused:
The 'x' icon on the upper right is the control box. If you go to your form style, under windows style, change the ControlBox property to 'false'. Although i'm not sure if the user can still close the window by pressing alt-f4. You may need to intercept the key event for this. -Steve
-
The 'x' icon on the upper right is the control box. If you go to your form style, under windows style, change the ControlBox property to 'false'. Although i'm not sure if the user can still close the window by pressing alt-f4. You may need to intercept the key event for this. -Steve