Dynamic selector not working


#1

Hello community right now i have this problem:

Inside a for each i assign the row index into a variable called “indice” = MiDTCiclo.Rows.IndexOf(row) + 1 where MiDTCiclo is the datatable no problem so far but in some condition is true i need to click on an item that belong to that row so i have the next selector:

but is not working like that, but if i change indice to 3 it works :confused: what could i do ?


#2

might be a problem with your selector. Try debugging using “Highlight” activity, to see where your selectors are pointing to at run time.

Btw I couldnt see your selector.! I think you missed it.


#3

Hello @kaderms yes my problem is on the selector . This is my selector:

<html app='firefox.exe' title='* - Autopase - Suscribe Pago Automático, Validac*' />

like this it works, but i want tableRow takes the value of “indice” in my debugg indice = 4 (valid value) so i put it like this:

tableRow=’“indice”’

but throws an error

I left my “code”:

Main.xaml (14.6 KB)


#4

I see some unwanted characters included in the selector, like the ones highlighted below.

This happens when you paste your dynamic selector into the Selector Editor dialog box.
Rather try concatenating the dynamic selector onto a single line (as you have multiple lines in your case), enclose it within double quotes. Like this (I have removed some lengthy selector elements to make it easy to show you.)

Clear the selector field and close Selector Editor. Click on the Selector field and paste the dynamic selector.

image

This should have your dynamic selector properly entered.
Your logic should work fine too.


#5

Thsnks , yes i read this in other post but thanks! :smiley: this should be on the tutorials videos xD