public static class ProcessExtensions { // Messages const int WM_KEYDOWN = 0x100; const int WM_KEYUP = 0x101; const int WM_CHAR = 0x105; const int WM_SYSKEYDOWN = 0x104; const int WM_SYSKEYUP = 0x105; private static class Win32 { [DllImport("user32.d…
函数原型 BOOL PostThreadMessage( DWORD idThread, UINT Msg, WPARAM wParam, LPARAM lParam ); 1 2 3 4 5 6 The PostThreadMessage function posts a message to the message queue of the specified thread. It returns without waiting for the thread to process the m…