如何传递从spy++;在sendmessage中使用c#?
如何传递我在sendmessage中使用spy++工具获得的句柄? 我想通过这个把手 从spy++00010540获得的句柄 在这个函数中如何传递从spy++;在sendmessage中使用c#?,c#,winapi,sendmessage,spy++,C#,Winapi,Sendmessage,Spy++,如何传递我在sendmessage中使用spy++工具获得的句柄? 我想通过这个把手 从spy++00010540获得的句柄 在这个函数中 SendMessage(buttonHandle, WM_HSCROLL, (IntPtr)SB_LINERIGHT, IntPtr.Zero); 其中按钮句柄的类型为IntPtr。我想用上面的值替换buttonhandle。 谢谢只需新的IntPtr(0x00010540)就可以了。例如: [DllImport("user32.dll", CharSet
SendMessage(buttonHandle, WM_HSCROLL, (IntPtr)SB_LINERIGHT, IntPtr.Zero);
其中按钮句柄的类型为IntPtr。我想用上面的值替换buttonhandle。
谢谢只需新的IntPtr(0x00010540)
就可以了。例如:
[DllImport("user32.dll", CharSet = CharSet.Auto)]
static extern IntPtr SendMessage(
IntPtr hWnd,
UInt32 Msg,
IntPtr wParam,
IntPtr lParam);
SendMessage(
new IntPtr(0x00010540),
0x0112, // WM_SYSCOMMAND
new IntPtr(0xF020), // SC_MINIMIZE
IntPtr.Zero);
只要新的IntPtr(0x00010540)
就可以了。例如:
[DllImport("user32.dll", CharSet = CharSet.Auto)]
static extern IntPtr SendMessage(
IntPtr hWnd,
UInt32 Msg,
IntPtr wParam,
IntPtr lParam);
SendMessage(
new IntPtr(0x00010540),
0x0112, // WM_SYSCOMMAND
new IntPtr(0xF020), // SC_MINIMIZE
IntPtr.Zero);