WinXSetPlacement


WinXSetPlacement (hWnd, minMax, RECT restored)

Sets information concerning how the window is displayed

Parameter Description
hWnd The handle to the window to set the information for
minMax The minimised/maximised state, see remarks for a list of possible values
RECT restored The restored size and position of the window.

Returns

$$TRUE on success or $$FALSE on fail

Remarks

The minMax parameter is one of these constants:

$$SW_SHOWMAXIMIZED
Makes the window maximised
$$SW_SHOWMINIMIZED
Makes the window minimised
$$SW_SHOWNORMAL
Does not maximise or minimise the window. The window size and position will be set the the restored parameter

Examples

' maximise a window (this is not the best way to do this,
' use ShowWindow Win32 API function instead)

WinXGetPlacement (#hMain, 0, @restored)
WinXSetPlacement (#hMain, $$SW_SHOWMAXIMIZED, restored)

Related Links

WinXGetPlacement
WinXDisplay
WinXShow
WinXHide