Use Traverse Mode for UIA Pro object identification
Traverse Mode provides a solution for identifying objects in applications with improper or incomplete UI Automation implementations.
What is Traverse Mode?
Traverse Mode is an enhancement to UIA Pro object identification. It enables you to identify objects in applications with improper or incomplete UIA implementations where the default spy mode fails to detect elements.
Instead of querying a point directly through UIA APIs (which may be improperly implemented or incomplete in the application), Traverse Mode scans the entire UI tree to find all objects at those coordinates.
This approach makes object identification more reliable and closely aligned with how OpenText Functional Testing for Developers performs object identification during test replay.
Enable Traverse Mode in the Object Identification Center
-
In your IDE, select Object Identification Center from the Functional Testing for Developers menu, or click the Object Identification Center toolbar button.
-
Click Start Spying to enter spying mode.
-
Hover over or select the desktop application window containing the control you want to identify.
-
In the OIC, locate the Traverse Mode option (visible in the UIA Pro identification section).
-
Check the Traverse Mode checkbox.
-
Use the OIC controls to navigate through the object hierarchy, selecting the target control.
-
Once you have identified your control, you can generate code by clicking the appropriate button in the OIC to copy the object identification code to your test.
When to use Traverse Mode
Traverse Mode is essential when you are working with applications that have improper or incomplete UIA implementations. The default UIA Pro spy mode relies on UI Automation to retrieve objects from a specific point on the screen.
Many applications do not properly implement or have incomplete support for UIA. This can cause elements not to be detected at all. It can also prevent OpenText Functional Testing for Developers from building accurate or complete object properties.
Enable Traverse Mode in these scenarios:
-
Detection failures: The default spy mode cannot detect objects at specific screen coordinates. This is the primary use case for Traverse Mode.
-
Incomplete information: Standard object identification returns incorrect or incomplete properties for objects in your application.
Performance considerations
Traverse Mode requires scanning the entire desktop tree structure, which may take longer than the default spy mode. Processing time depends on machine performance, the number of open applications, and available system resources.
Unlike the default spy mode, Traverse Mode is not real-time and requires waiting for completion. Additionally, Traverse Mode returns multiple hierarchies. It returns all leaf objects at the specified coordinates with their complete ancestor chains, rather than a single object.
Availability
Traverse Mode is specific to UIA Pro object identification. It is not available for other technology add-ins (such as Java, Web, or WPF).
Tip: If you encounter applications where the default spy mode cannot detect certain objects, try enabling Traverse Mode to see if it can identify them successfully.
See also:

