Disable the Alt+F4, Alt+Tab,F4 keys through c# program

D

Dev

Hello,
How do disable the Alt+F4, Alt+Tab,F4 keys through c# program?
If anyone know please let me know..... sample code or reference link.

Thanks in Advance for all help and suggestions!!!!!!

Thanks,
Dec
 
J

Joe White

To disable Alt+F4, just add a Closing event handler to your form and set
e.Cancel to true.

I don't think you can disable Alt+Tab. Win32 platforms are
cooperative-multitasking systems. Preventing task-switching goes
against the whole intent of the OS.

I haven't seen that F4 by itself does anything, so I'm not sure what
you're trying to prevent there.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top