Function SendInput 
Author Message
 Function SendInput

void CTestView::OnKeyDown(UINT nChar, UINT nRepCnt, UINT
nFlags)
{
        // TODO: Add your message handler code here and/or
call default

   CView::OnKeyDown(nChar, nRepCnt, nFlags);
   INPUT inputStruct;
   inputStruct.type=INPUT_MOUSE;
   inputStruct.mi.dwFlags=MOUSEEVENTF_MOVE;
   inputStruct.mi.mouseData=0;
   inputStruct.mi.dx = 5;
   inputStruct.mi.dy = 12;
   SendInput(1,&inputStruct,sizeof(INPUT));

Quote:
}

use it some time ,have cause the screen trun to black
like  as sleep.

in the stdfx.h:
#include <winuser.h>
#include <winable.h>

  testView.cpp
4K Download


Tue, 26 Apr 2005 09:14:13 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. importing the sendInput function from user32.lib

2. SendInput Function

3. SendInput() issue...

4. SendInput

5. Win32 API SendInput()

6. SendInput

7. SendInput MOUSEINPUT question

8. keybd_event / SendInput

9. SendInput and BlockInput

10. SendInput

11. SendInput works partially

12. How to use 'SendInput'

 

 
Powered by phpBB® Forum Software