Method Reference
WinExists
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, WinTitleMatchMode (Option), WinWait, WinWaitActive, WinWaitClose, WinWaitNotActive
Example
Set oAutoIt = WScript.CreateObject("AutoItX3.Control") If oAutoIt.WinExists("Untitled -") Then WScript.Echo "Window exists" EndIf