Hi,
I have a scenario for which any help is much appreciated.
I have a table in a webpage. One particular column in that table has links (say column B). For each row in that table,i will have to go to column B, click on that link and perform some actions. I am familiar with ‘For each row’ activity when we are using an excel application. But how will i navigate through a table in a webpage.
I was able to get all the buttons in the table, but when i use ‘for each’ activity to loop and ‘click’ activity to click on that link, i end up clicking the same link 3 times (refer sample screen). can you pls let me know what m doing wrong here
If I were guessing, when you added your Click TD, you just selected from the page and it’s just looping through and clicking with the same selector. Instead of using the Find Children activity, you may be able to use Data Scraping. It allows you to include both the column name and the underlying link in the dt. You can then use that in your selector.
I used the ‘find_descendants’ as my ‘scope’ in 'find children activity.
In ‘selector’,I chose the whole table and in ‘filter’ i have this “”
When i verified this with ‘writeline’ it aptly says the count is ‘3’. (as in,there are 3 links in the table)
I tried dynamic click, but when i use ‘child’ as my element in ‘for each child’ loop, it is just clicking the first link once. For the second ‘child’ or the second ‘link’ it is unable to find.
@Krishna_Prashanth
Use DataScraping to extract the data and store it in a datatable
Then Use For each row
Take the selector for Decision element and check how it’s varying for each row
Then create a dynamic selector and pass into Click Activity inside Foreach row
@Krishna_Prashanth
Since the tableRow is incrementing by one just create one integer inta and intialise it by 2
then
add this ‘“+inta.ToString+”’ in tablerow tag
Then after Click activity increment the value by one inta=inta+1