Home > Software engineering >  How to send the mouse wheel to the game window messages?
How to send the mouse wheel to the game window messages?

Time:10-03

Don't tried the following method, effect, I don't know how make of?

WPARAM WPARAM=0 xff880000;//0 x00780000 roller rolling up; 0 xff880000 roller rolling down
LPARAM LPARAM=0 x02c0025b;
Sleep (3000);
: : SendMessage ((HWND) 20186410, WM_MOUSEWHEEL wParam, lParam);//roll up

: : PostMessage ((HWND) 20186410, WM_VSCROLL SB_LINEDOWN, 0).//roll down
: : PostMessage ((HWND) 20186410, WM_VSCROLL SB_LINEUP, 0).//roll up

Make the show a ah ~

CodePudding user response:

Try SendInput

CodePudding user response:

Are there any examples? The roller

CodePudding user response:

 
Void CSDI3View: : OnLButtonDown (UINT nFlags, CPoint point)
{
//TODO: Add your message handler code here and/or call the default

Mouse_event (MOUSEEVENTF_WHEEL, 0, 0, WHEEL_DELTA * - 20, 0).

CScrollView: : OnLButtonDown (nFlags, point);
}

CodePudding user response:

Mouse_event this cannot be the background
  • Related