CWindow::SendMessage

LRESULT SendMessage( UINT message, WPARAM wParam = 0, LPARAM lParam = 0 );

static LRESULT SendMessage( HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam )

See SendMessage in the Win32 SDK.

Remarks

Sends a message to the window and does not return until the window procedure has processed the message.

Example

// The following example attaches a HWND to the CWindow
// object and sends a WM_PAINT message to the window
// wrapped by CWindow object using CWindow::SendMessage.

CWindow myWindow;
myWindow.Attach(hWndFoo);   
myWindow.SendMessage(WM_PAINT,0L,0L);

CWindow OverviewClass Members

See Also   CWindow::PostMessage, CWindow::SendNotifyMessage, CWindow::SendMessageToDescendants