system.vision.findWindow
This function replaces system.gui.findWindow. Any scripts containing Vision Client scoped functions that were replaced with system.vision syntax will still work to maintain backwards compatibility.
This function is used in Python Scripting.
Descriptionβ
Finds and returns a list of windows with the given path. If the window is not open, an empty list will be returned. Useful for finding all instances of an open window that were opened with system.vision.openWindowInstance.
This function is available on secondary desktops via the system.vision.desktop function. See the Multi-Monitor Clients page for more details on secondary desktops.
Client Permission Restrictionsβ
This scripting function has no Client Permission restrictions.
Syntaxβ
system.vision.findWindow(path)
Parametersβ
| Type | Parameter | Description |
|---|---|---|
| String | path | The path of the window to search for. |
Returnsβ
List - A list of window objects. May be empty if window is not open, or have more than one entry if multiple windows are open.
Scopeβ
Vision Client
Code Examplesβ
# This example finds all open instances of the window named "Popup" and closes them all.
allInstances = system.vision.findWindow("Popup")
for window in allInstances:
system.vision.closeWindow(window)