locked
Can I use raw input replace global hook ? RRS feed

  • Question

  • Hi all,

    Can I use raw input replace global hook?

    for example, If I want monitoring the keyboard message, and have register the keyboard to receive raw input,

    can I receive the message  if the application is not get focus ?

    thanks!

    • Moved by ThankfulHeart Saturday, August 4, 2012 4:57 AM .NET General Question (From:.NET Framework 一般性问题讨论区)
    Friday, August 3, 2012 10:13 AM

Answers

  • It works for mouse input, so I think yes.  But the best idea would be for you to try it out.

    Jose R. MCP
    Code Samples

    • Proposed as answer by Mike Feng Monday, August 6, 2012 8:22 AM
    • Marked as answer by Mike Feng Thursday, August 16, 2012 9:26 AM
    Monday, August 6, 2012 5:31 AM
  • Hi Rytian,

    Welcome to the MSDN Forum.

    Based on this article, I also think you can: http://msdn.microsoft.com/en-us/library/windows/desktop/ms645543(v=vs.85).aspx 

    The raw input model and the associated APIs were developed to allow simple access to raw input from all input devices, including the keyboard and mouse.

    And it has some advantages. So it is worth to try.

    Best regards,


    Mike Feng
    MSDN Community Support | Feedback to us
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    • Marked as answer by Mike Feng Thursday, August 16, 2012 9:26 AM
    Monday, August 6, 2012 8:27 AM

All replies

  • It works for mouse input, so I think yes.  But the best idea would be for you to try it out.

    Jose R. MCP
    Code Samples

    • Proposed as answer by Mike Feng Monday, August 6, 2012 8:22 AM
    • Marked as answer by Mike Feng Thursday, August 16, 2012 9:26 AM
    Monday, August 6, 2012 5:31 AM
  • Hi Rytian,

    Welcome to the MSDN Forum.

    Based on this article, I also think you can: http://msdn.microsoft.com/en-us/library/windows/desktop/ms645543(v=vs.85).aspx 

    The raw input model and the associated APIs were developed to allow simple access to raw input from all input devices, including the keyboard and mouse.

    And it has some advantages. So it is worth to try.

    Best regards,


    Mike Feng
    MSDN Community Support | Feedback to us
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    • Marked as answer by Mike Feng Thursday, August 16, 2012 9:26 AM
    Monday, August 6, 2012 8:27 AM