Window::PostMessage

Contents

Description

Places a message in the message queue associated with the thread that created the window. Returns without waiting for the thread to process the message.

Syntax

BOOL PostMessage( uint msg, DWORD wParam = 0, DWORD lParam = 0 )

Parameters

msg
[input] Specifies the message to be sent.
wParam
[input] Specifies additional message-dependent information.
lParam
[input] Specifies additional message-dependent information.

Return

The result of the message processing; its value depends on the message sent.

Examples

EX1

int Window_PostMessage_ex1()
{
    GraphPage gp;
    gp.Create("origin.otp");

    Window myWindow = gp.GetWindow();
    myWindow.PostMessage(WM_CLOSE);
    if(gp.IsValid())
        out_str("Error: gp should be destroy.");
    return 0;
}

Remark

See Also

header to Include

origin.h