UI automation navigator

UIA Navigator - Click for a larger image

Object Studio provides two primary ways of identifying user interface elements to use in visual business objects.

The spy tool can pick out visual elements to automate, or you can use one of the application navigator forms to traverse the UI model and identify which element is required in the model.

There are currently two different navigators – one exposes the Win32 and Active Accessibility model, and the one that this page describes exposes the UI Automation model. Fundamentally, they work in exactly the same way, with only minor variations specific to the model types that they are exposing.

Open the UI automation navigator

Opening the navigator

The UI Automation navigator form can be opened by launching or attaching to the target application in Object Studio, then creating an element. When the new element is selected, a split button labelled Identify will be shown. If you click on the drop down menu part of the button, it will show a menu containing:

  • Spy Element
  • Open Application Navigator
  • Open UI Automation Navigator

The navigator form can be opened by selecting the last of those options.

The form will open and load the model into the tree on the left hand side. When an element is selected in the tree, it is highlighted in the application and its UI Automation attributes are displayed in the grid on the right.

Change the view

The UI Automation Raw View

The UI Automation model allows elements to be categorised into specific views, namely, from most general to most specific, 'Raw', 'Control' and 'Content'. The views can be broadly described as follows:

  • Raw View – The full tree of automation elements which closely follows the native programmatic structure of an application. This is the most detailed view available.
  • Control View – This is a subset of the raw view. It contains elements which show information to the user or enable the user to perform an action. It can also contain noninteractive UI elements which contribute to the logical structure of the UI, such as list view headers, toolbars and menus. Noninteractive elements used only for layout or decoration, such as panels used to lay out controls, do not appear in the control view.
  • Content View – This is a subset of the control view. It contains elements which convey information in a user interface, including UI elements that can receive keyboard focus and some text that is not a label on a UI element.

More information on UI Automation views is available on the MSDN UI Automation Tree Overview page.

The default view used by the navigator in Blue Prism is 'Control', but you can change the current view by selecting the desired view in the top left of the form.

Note that some views alter the hierarchy such that the parent of an element in the 'Control' view may differ from the parent of the same element in the 'Raw' view. This makes no difference to the element stored in the VBO's application model when an element is selected – the view will not affect the parent data which is stored against a selected element.

Filter the model

Filtering the UI Automation model

The model can be filtered by entering a search term in the filter box above the model. On pressing enter or after stopping typing for a short while, the tree will be filtered such that it will only contain elements whose names or selected attributes contain the filter text.

The filter text can be cleared by pressing the red 'x' on the right of the filter text box.

Hide or show the attributes

Hiding the attributes

The visibility of the attribute list can be toggled by clicking on the button at the middle top of the form. This has no functional effect beyond the simplification of the interface.

Select an element

The element can be added into the application model by pressing the OK button after choosing the desired element in the tree.

To cancel a selection, the Cancel button can be pressed. This will close the navigator form with no change made to the underlying application model.