开发者

How do I listen for a keyboard combination globally?

How would I have my C# program listen for a specific keyboard combination (say, CTRL + ALT + F2) globally. Even if my application is minimized I would want 开发者_开发问答it to intercept this and do something.


You will have to use the Windows API to set a system hook into the keyboard. Here is a pretty good article on how to do such a thing:

http://www.codeguru.com/vb/gen/vb_system/keyboard/article.php/c4829/

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜