Use UI Window
A Use UI Window building block is used to switch focus to a specific UI window when working with Desktop UI automation.
Fully expanded, the Use UI Window block shows the following properties:
The Block Header (“Use UI Window”)
The green input connector in the header is used to trigger the block to start executing.
The green output connector in the header triggers when the UI element has been successfully found.
The title of the block (“Use UI Window”) can be changed by double-clicking on it and typing in a new title.
By default, the “Element” method is selected as source for Desktop application under test, user can also “Define” the criteria based on options available (mentioned below)
By setting this property, the UI element locator will work inside the provided source element, instead of working on a captured element.
This means it’s possible to capture a row in a table in one building block, and by using the source property making it easy to find and click a particular cell or field in that exact row.
This will attempt to find a window based on user defined criteria.
Add Condition (mandatory with “Define”)
You can add multiple conditions to find desired window using “Add condition” button.
Where (mandatory with “Define”)
Choose one of the three option to define where condition (mentioned below)
Method (mandatory with “Define”)
Select condition to use when attempting to find the desired UI window by either by Title, Process Name or Execution path. The condition options are:
Value (mandatory with “Define”)
The text to be used to find the desired window.
This green output connector triggers if the UI element is not found within the time specified in the timeout field (see below). If no building blocks are attached to this connector and the element is not found, then the case will end in status Fail.
This connector can be used to branch the execution of the flow depending on whether the element is found or not.
Once desktop application window is found and focus is set, this property contains a handle to the window. This can be used in cases where multiple application windows are opened during a case run, to direct other building blocks to use a specific window.
The maximum time spent searching for the Application UI element before giving up and triggering “Not found” (see above).
The default value is 10 seconds.
Note: All cases have a “global timeout” that can be configured in the “Settings” panel. This is unrelated to the timeout of a single building block. However, a running case will automatically be cancelled if it runs for longer than the global timeout.Author: March 23, 2017. ,