From tables such as the one below, I want to capture the Dates, the Inv Nr and Amount, plus I need to click on the top button in col 2 to open a sub-page from which further data can be captured.
Using “Data Scraping” to identify the table rows and columns, with a “for every row” loop, I can capture Inv Nr and Amount, but the dates in col 0 and buttons in col 1 appear to be blank when I try to visualize what I’ve captured (eg using Write Line: row(“Inv Nr”).ToString + " " + row(“Amount”).ToString + “…” + row(1).ToString + “…” + row(3).ToString)); the preview of the table from “Data Scraping” is as follows:
So I would like to know how to capture the dates that appear in the pre-view (into variables) and how to click the button. I think this boils down to knowing exactly what what data is captured by the “Data Scraping” activity (perhaps button selectors aren’t).
I tried a second tack. Using “Find Children” of the table with a suitable filter for each column, then looping through the children with a For next. I can find the button’s selector, and the selectors for the Amount and Inv Nr. The Inv Nr and Amount is extracted using “Get Attribute” (aaname) (I haven’t tried to get the dates). Because the “Find Children” filter needs to be different for each column, I can’t co-coordinate the values (ie click the button corresponding to a specific Inv Nr).
The filters needed are:
“webctrl css-selector=‘body>div>div>div>div>div>div>div>table>tbody>tr>td>div>button>i’ idx=‘1’ tag=‘I’ /” … … … … … … … button
“webctrl parentid=‘loaded’ tableCol=‘3’ tag=‘A’ /” … … … … …Inv Nr
“webctrl isleaf=‘1’ tableCol=‘5’ tag=‘TD’ /”… … … … … … … …Amount
The six children found by the button filter needs an IF - InStr(child.Selector.ToString,“idx=‘1’”) > 0
The Inv Nr filter finds just selectors for the three rows.
The six children found by the Amount needs an IF - (Get attribute) result.Trim <> “”
A solution would be greatly appreciated.
AJ