Wait Window
Waits for a window to appear or disappear within a specified timeout period.
Common Properties
- Name - The custom name of the node.
- Color - The custom color of the node.
- Delay Before (sec) - Waits in seconds before executing the node.
- Delay After (sec) - Waits in seconds after executing node.
- Continue On Error - Automation will continue regardless of any error. The default value is false.
info
If the ContinueOnError property is true, no error is caught when the project is executed, even if a Catch node is used.
Inputs
- Window Selector - The selector for identifying the target window.
Options
- Condition - The condition to wait for. Default is no action.
- To Appear - Wait for the window to appear
- To Disappear - Wait for the window to disappear
- Timeout - The maximum time (in seconds) to wait for the condition. Default is 30 seconds.
How It Works
The Wait Window node pauses execution until a specified window either appears or disappears. When executed, the node:
- Uses the Window Selector to identify the target window
- Based on the Condition option:
- To Appear: Continuously checks for the window's existence until it appears or timeout
- To Disappear: Continuously checks for the window's existence until it disappears or timeout
- Checks for the window every 0.5 seconds during the wait period
- Raises a TimeoutError if the condition is not met within the specified timeout
Requirements
- A valid Window Selector is required to identify the target window
- Valid timeout value (positive integer)
Error Handling
The node will return specific errors in the following cases:
- Empty or invalid Window Selector
- No Condition selected
- Timeout exceeded while waiting for the window condition
- Window cannot be located due to accessibility issues
Usage Notes
- This node is useful for synchronizing automation with window-based operations
- Use "To Appear" when waiting for windows that are created or shown after some operation
- Use "To Disappear" when waiting for windows that are closed or hidden after some operation
- The timeout value should be set appropriately based on expected window response times
- This node helps prevent race conditions in automation workflows
- For windows that may temporarily disappear and reappear, consider using appropriate timeout values