WinSetStyle()

Auto Hotkey

WinSetStyle

Changes the style of a window, respectively.

WinSetStyle Value , WinTitle, WinText,  ExcludeTitle, ExcludeText
Command  Example: WinSetStyle "-0xC00000", "A"
Function Example: WinSetStyle("-0xC00000", "A")

Parameters

Value

If the first character of Value is a plus or minus sign, the style(s) in Value are added or removed, respectively. If the first character is a caret (^), the style(s) in Value are each toggled to the opposite state. If the first character is a digit, the window's style is overwritten completely; that is, it becomes Value.

WinTitle

A window title or other criteria identifying the target window. See WinTitle.

WinText

If present, this parameter must be a substring from a single text element of the target window (as revealed by the included Window Spy utility). Hidden text elements are detected if DetectHiddenText is ON.

ExcludeTitle

Windows whose titles include this value will not be considered.

ExcludeText

Windows whose text include this value will not be considered.

Remarks

Window titles and text are case sensitive. Hidden windows are not detected unless DetectHiddenWindows has been turned on.

Related

WinHide, WinSetTitle, WinMove, WinActivate, Control

Examples

WinSet, Style, -0xC00000, A  ; Remove the active window's title bar (WS_CAPTION).