SendMessage

From ReliCodia

(Redirected from API:SendMessage)
LRESULT SendMessage (
   HWND hWnd,
   UINT Msg,
   WPARAM wParam,
   LPARAM lParam
);

SendMessage is a formalized way of calling a Window Procedure. The arguments to SendMessage are exactly the same as the ones expected by Window Procedure

  • hWnd--handle to the window whose procedure that we are calling
  • Msg--the message identifier
  • wParam and lParam--message-dependend parameters

SendMessage returns only after the message has been processed. It returns the value (also message-dependent) returned by the Window Procedure.

Implementations

SendMessage can be used in Visual Basic and Visual Basic.NET using the definitions shown below

See also: PostMessage, SendMessageCallback, SendNotifyMessage