win32gui.SendMessageTimeout

int,int = SendMessageTimeout(hwnd, message , wparam , lparam , flags , timeout )

Sends a message to the window.

Parameters

hwnd : int

The handle to the Window

message : int

The ID of the message to post

wparam : int

An integer whose value depends on the message

lparam : int

An integer whose value depends on the message

flags : int

Send options

timeout : int

Timeout duration in milliseconds.

Return Value

The result is the result of the SendMessageTimeout call, plus the last 'result' param. If the timeout period expires, a pywintypes.error exception will be thrown, with zero as the error code. See the Microsoft documentation for more information.