CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Dec 2004
    Posts
    21

    Wink How to catch keyboard event before the operation system ?

    I need to catch every keyboard event before operation system ( windows xp ) does.

    What i mean is in case user click on key 'enter' ( or every other key ) my application need to check if the key is 'X' key - and in any case this key event need to continue as key event to the operation system.

    I'm sure there is some win32 API function to do it - but i don't remember it.

    Someone can help me ?

    Thanks.

  2. #2
    Join Date
    Feb 2000
    Location
    San Diego, CA
    Posts
    10,354

    Re: How to catch keyboard event before the operation system ?

    SetWindowHookEx

  3. #3
    Join Date
    Dec 2004
    Posts
    21

    Re: How to catch keyboard event before the operation system ?

    I looking in the MSDN about this function - i don't understand how can i catch the key ( know what key was press ).

    My application don't supposed to run as MFC application - its need to run in the background [ like keyboard logger ].

  4. #4
    Join Date
    May 2005
    Posts
    4,954

    Re: How to catch keyboard event before the operation system ?

    This article might help you: KeyBoard Hooks

    Cheers
    If a post helped you dont forget to "Rate This Post"

    My Article: Capturing Windows Regardless of Their Z-Order

    Cheers

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured