Clicking an item on URL based on TEXT found from "read CSV"

Hi
I’m wondering what the best activity to use on Web-based page to find TEXT and then based on this text click on an icon

I’m assuming I need to put these to activites into ANCHOR

Thanks

Use click Ocr text and pass the value from read csv to it @KarenL

Hi @KarenL

You can create your selector at runtime basis and pass that to Click activity if your click activity attributes have that value in the selector…

Read articles of how to tweek selectors.

Thanks I have tried this but cant work out where I need to add in the “Text”
As the “TEXT” doesnt appear anywhere in Selector for me to replace it with Row(“… Column name”).ToString

Hi,

I think values are placed in Data table via which you can find the Table row and replace that on runtime.

  1. Extract Data Table
  2. Search for your value in Column of data table with assigning Default row value 0 and adding +1 until you find your value.
  3. then pass that row number to your selector to click.

Hope this helps. Give a try and let us know.

Regards,
Ashish

Not sure if this will work as I don’t need to click TEXT, I need to click the ICON 4 x Columns to the left of the TEXT found

image

You can still click that icon based on the matching selector of the text. You’d want to match the text then use the row it is on in the pictured table to click the corresponding icon on the same row. You may also check out relative elements using the UI Explorer as it may work for this use case.

1 Like

@KarenL, Go with anchor base

Thanks Tyler… but I’m a bit lost of what your suggesting
I maybe completely on wrong track as im still fairly new to Selectors

Selector example for what I need to click on is:
<webctrl parentid=‘membershipsGrid’ tableRow=‘3’ tag=‘IMG’ />

Selector =example for what I need to find is:
<webctrl id=‘membershipsGrid’ tag=‘TABLE’ />
<webctrl isleaf=‘1’ tableCol=‘5’ tableRow=‘3’ tag=‘TD’ />

Note: tableRow=‘3’ - changes depending on which line the text will appear

I was thinking i need to add after TD …aaname=‘”+row(“Number”).ToString+”’ />
To identify the TEXT to find (NUMBER is column name in my Read CSV)

I tried to use Select Relative Element - in UI Explorer but I get this

Hi @KarenL

Please check this xaml which can give you an idea of how to create selectors…

Regards,
Ashish

Main.xaml (13.6 KB)