Hello everyone, I would like to write an application that would allow me to change the functions of the usually-useless F keys (especially F8, I hate that one) into functions that I specify in code. I would like to let some of them open certain files, or paste text.. etc
So how can I modify and disable key functions in C# without using hooks?
To clarify, are you wanting to change these keys for the system, or just within/for your running application?
As long as the application is running, however the change would be universal across the system.
For example I'd change the F5 key to something other than refresh, so even if I go to Firefox or the desktop and press F5, the system would perform my function, not refresh.
Ideally, I'd save my changes as settings; and whenever I run my app, it would apply the modifications indicated by the settings and keep them until the application terminates.
I don't think you should be remapping keys across the entire system, unless you are creating a key mapping program that the user is in complete control over, including the ability to restore all previous/normal key mappings.