Highlighted
cwBrendan Absent Member.
Absent Member.
2107 views

Record locators - use window id instead of caption

Jump to solution

When using the "Record Locators" function of the Open Agent it defaults to using the caption of a control in the locator e.g. "//PushButton[@caption='New']". If I stop the recorder and click the "Show additional locator attributes" it will display the window id but is there any way to make window id the default? It would be much easier if I could simply find the locator and paste it into my code instead of having to type in the window id manually. 

e.g. I want to get "//PushButton[@windowid='102']" for the locator instead of the one above.

Tags (2)
0 Likes
1 Solution

Accepted Solutions
JohnG2 Absent Member.
Absent Member.

RE: Record locators - use window id instead of caption

Jump to solution

Hi, from the Settings menu you can launch the Script Options dialog, and from there select the Custom Attributes tab to define custom attributes, e.g. windowid, for the tech domain you are recording in.  Or, for browser applications select the Browser tab and from there use the attribute name or value exclude lists.

John

0 Likes
2 Replies
JohnG2 Absent Member.
Absent Member.

RE: Record locators - use window id instead of caption

Jump to solution

Hi, from the Settings menu you can launch the Script Options dialog, and from there select the Custom Attributes tab to define custom attributes, e.g. windowid, for the tech domain you are recording in.  Or, for browser applications select the Browser tab and from there use the attribute name or value exclude lists.

John

0 Likes
cwBrendan Absent Member.
Absent Member.

RE: Record locators - use window id instead of caption

Jump to solution

Perfect, thanks!

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.