We help IT Professionals succeed at work.

Check out our new AWS podcast with Certified Expert, Phil Phillips! Listen to "How to Execute a Seamless AWS Migration" on EE or on your favorite podcast platform. Listen Now


trapping key strokes when not current app

dob1 asked
Medium Priority
Last Modified: 2010-04-04
I want to be able to process keystrokes when users are not in my form. Specifically I want to know when the user presses the escape key at any time, but I would imagine that the same procedure applies to trapping all keys.

I have found some info on this message board about trapping keys when your app has focus, but none about general windows keyboard trapping.
Watch Question

I think that you can stand infront of the user and when they hit the keys that you want to trap, push them out of the way to initiate your event. How does this sound?
see Intercepting keystrokes in:
Unlock this solution with a free trial preview.
(No credit card required)
Get Preview

Doesn't catch keys from other windows; only form1.
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a free trial preview!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.


Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.