CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 2 of 2
  1. #1
    Guest

    How to generate system level input message, such as keyboard and mouse?

    Hi, all,
    My programme have to generate the system level keyboard message and mouse message, such as type some key, mouse move, mouse clike, etc. How to generate them?
    Note they should be system level, that means these message could be dispatched to the system, not only just a active programe.



  2. #2
    Join Date
    May 1999
    Posts
    216

    Re: How to generate system level input message, such as keyboard and mouse?

    Use SendMessage function to send messages(or PostMessage to post to the message Queue)
    WM_KEYUP and WM_LBUTTOBCLICK (refer similar messages) are used to simulate the inputs.
    Use PostMessage with parameter as HWND_BROADCAST to post to system
    Ravi


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