Compartilhar via


CWindow::SendMessage

Envia uma mensagem para a janela e não retornar até que o procedimento de janela processou a mensagem.

LRESULT SendMessage(
   UINT message,
   WPARAM wParam = 0,
   LPARAM lParam = 0 
) throw();
static LRESULT SendMessage(
   HWND hWnd,
   UINT message,
   WPARAM wParam,
   LPARAM lParam 
) throw();

Comentários

See SendMessage in the Windows SDK.

Exemplo

// 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(hWnd);   
myWindow.SendMessage(WM_PAINT, 0L, 0L);

Requisitos

Cabeçalho: atlwin.h

Consulte também

Referência

Classe CWindow

CWindow::PostMessage

CWindow::SendNotifyMessage

CWindow::SendMessageToDescendants

Outros recursos

CWindow membros