Recent

Author Topic: Detect which key was pressed in the active/foreground window  (Read 2703 times)

balazsszekely

  • Guest
Detect which key was pressed in the active/foreground window
« on: January 30, 2015, 05:47:26 am »
A few days ago, a user asked if it's possible to capture keys pressed in the active window. After he got the answer, strangely enough he/she deleted the thread. I believe knowledge should be free and available to everyone, especially in this open source community. So if anybody is still interested in how to capture pressed keys, check the attachment.  It's a low level keyboard hook, for more technical details, please read this msdn entry:
https://msdn.microsoft.com/en-us/library/windows/desktop/ms644990%28v=vs.85%29.aspx

engkin

  • Hero Member
  • *****
  • Posts: 3112
Re: Detect which key was pressed in the active/foreground window
« Reply #1 on: January 30, 2015, 05:54:39 am »
Thanks for sharing.  :)

 

TinyPortal © 2005-2018