I did overcome one selector problem by editing the selector that UiPath Explorer offered (it had not discovered the full variability of a reference number in the selector, which changed on every page refresh). I was advised to capture the same selector a number of times and paste them into Notepad for comparison, and then further adjust the selector offered by UiPath Explorer. This worked
Perhaps the following will indicate how subtle selector selection can be. On this Web page pane…
I want to scrape the date (19-Sep-2017), and the balance (4,666.12), which, of course, are both dynamic.
UiPath Explorer suggests:
webctrl aaname='*2017' parentid='loaded' idx='1'
This captures the date correctly, but it will fall over in a few months, of course.
Changing the selector to:
webctrl aaname='*' parentid='loaded' idx='1'
returns “1127”, which means it must be coming from some other part of the Web page (it’s actually an internal reference number: “company ID”). But using:
webctrl aaname='??-???-????' parentid='loaded' idx='1'
correctly returns the date .
Similarly, recording the sequence for the balance value, as you would expect, identifies the selector as:
webctrl aaname='4,666.12' parentid='loaded' tag='DIV'
Replacing the dynamic value with a placeholder:
webctrl aaname='*' parentid='loaded' tag='DIV'
Returns a title “Bank Accounts” from the Web page (not the balance value required), which turns out to have the selector:
webctrl aaname='Bank Accounts' parentid='loaded' tag='DIV'
Using the following selector works :):
webctrl aaname='*.??' parentid='loaded' tag='DIV'
In this situation, where a selector wildcard matches a selector preceding the one required, is there a way of asking for the second (or nth) instance of a wildcard selector, for example, rather than relying on some embedded character(s) in the string required (which might not always be available)?
AJ