BOOL PostThreadMessage(
  DWORD idThread, // thread identifier
  UINT Msg,       // message
  WPARAM wParam,  // first message parameter
  LPARAM lParam   // second message parameter
);应该可以把

解决方案 »

  1.   

    可能是我问题没有说清楚
    UINT SetTimer(
      HWND hWnd,              // handle of window for timer messages
      UINT nIDEvent,          // timer identifier
      UINT uElapse,           // time-out value
      TIMERPROC lpTimerFunc   // address of timer procedure
    );
    我没有窗口hwnd=NULL,没有timeproc,lpTimerFunc==NULL
    它会在超时是向当前线程发送消息WM_TIMER,但是
    GetMessage得到LPMSG的其它内容应在什么地方填充? 
      

  2.   

    hwnd设为NULL,消息就会向当前窗口发,当然是在当前窗口的OnTimer里面填充。
      

  3.   

    WM_TIMER 
    wTimerID = wParam;             // timer identifier 
    tmprc = (TIMERPROC *) lParam;  // address of timer callback 
    明白?
      

  4.   

    MSG Msg = { 0 };
    ::GetMessage( &Msg,....
    GetMessage函数自己得到消息种类。
      

  5.   

    谢谢ahao,我明白了,难道我想在WM_TIMER消息中发送两个字符串就没有办法了么?