PeekMessage(&msg,NULL,OU,OU,PM_NOREMOVE);
我在一个例子中看到的,中间那两个OU到底是什么东西,系统说未定义,但是编译运行都是通过的。

解决方案 »

  1.   

    BOOL PeekMessage(
      LPMSG lpMsg,         // message information
      HWND hWnd,           // handle to window
      UINT wMsgFilterMin,  // first message
      UINT wMsgFilterMax,  // last message
      UINT wRemoveMsg      // removal options
    );Parameters
    lpMsg 
    [out] Pointer to an MSG structure that receives message information. 
    hWnd 
    [in] Handle to the window whose messages are to be examined. The window must belong to the current thread. 
    If hWnd is NULL, PeekMessage retrieves messages for any window that belongs to the current thread. If hWnd is INVALID_HANDLE_VALUE, PeekMessage retrieves messages whose hWnd value is NULL, as posted by the PostThreadMessage function. wMsgFilterMin 
    [in] Specifies the value of the first message in the range of messages to be examined. Use WM_KEYFIRST to specify the first keyboard message or WM_MOUSEFIRST to specify the first mouse message. 
    If wMsgFilterMin and wMsgFilterMax are both zero, PeekMessage returns all available messages (that is, no range filtering is performed). 那两个参数为0U,返回所有可能的消息。
    U表示无符号