Could not deactivate CTRL+F4(close window)

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Despite setting controlbox property to false, CTRL+F4 shortcut is still
working.
Anyone can help me to disable CTRL+F4?

Raj kumar
 
In the Form's KeyDown event handler, add code like this:
If e.KeyCode = Keys.F4 Then If e.Control Then e.Handled = True
Augment with Not e.Alt and/or Not e.Shift if you wish to exclude those
modifiers.
You will also need to set the form's KeyPreview property to True.
 
Thanks for answer.
However i still need help

Actually my application has activeX control(axWebBrowser1) that displays
java applet. When there is no applet loaded into the control this code is
trapped /handled otherwise not.
 
Back
Top