::SendMessage(GetSafeHwnd(),WM_ACTION,0,0); ::SendMessage(GetSafeHwnd(),WM_ACTION,0,0); if you want to get the result as you say,you should write like these. when we use postmessage to send the message,the application only send the message to CWnd,then return,the application does not wait for the Command to be carried out. when we use sendmessage to send the message,the appliation return when the command be carried out.If we does not wait for the command to be carried out.The message will be save in the message queue, so the message is FILO,not FIFO zhengyb@nanjing-fnst.com