Checks to see if a specified window exists.
WinExists "title" [, "text"]
Parameters
title | The title of the window to check. |
text | [optional] The text of the window to check. |
Return Value
Returns 1 if the window exists, otherwise returns 0.
Remarks
WinExist will return 1 even if a window is hidden.
Related
WinActive, WinWait, WinWaitActive, WinWaitClose, WinWaitNotActive, WinTitleMatchMode (Option)
Example
Set oAutoIt = WScript.CreateObject("AutoItX3.Control")
If oAutoIt.WinExists("Untitled -") Then
WScript.Echo "Window exists"
EndIf