Dynamic Selector is not working while trying to click on radio button in a table


#1

Hi Team,

I am using a click activity to click on a radio button in a table. The table structure is table inside table hence attribute tableRow will always be 1.

Here I am using the idx value to find the correct radio button. If I use the below selector then click is working:

with idx value:
webctrl parentid=‘dojox_grid__View_3’ tag=‘TABLE’ idx=‘9’ />
webctrl tableCol=‘1’ tag=‘TD’ />

But if I pass the variable then it is throwing “Can not find the UI element” exception.

using variable:
webctrl parentid=‘dojox_grid__View_3’ tag=‘TABLE’ idx=’("+count.ToString()+")’ />
webctrl tableCol=‘1’ tag=‘TD’ />

Please help.


#2

can you provide the selector?


#4

added


#5

@thepathbreaker,

Remove those parantheses. It should be idx='"+count.ToString()+"'

Regards,
Dom :slight_smile:


#6

thanks for the reply @Dominic

first I tried without parentheses but same problem.


#7

Hi @thepathbreaker

you are clicking the table td cell only not clicking the radio button.

Try to get selector for radio button

are you using web application or windows based application?

Regards,
Arivu


#8

@thepathbreaker, Quickly three things to mind, (That I have)

  1. Print the selector you frame (as string ) in a Log message to confirm there is no syntatical error. (No difference from the 1 & 2 that you have described above)
  2. Refresh the page to check the idx remains same at all times.
  3. Probably go for some other attributes (Might be CtrlId…)

Regards,

Dom :slight_smile:


#9

Actually the selector for radio button is bit complicated that’s why I am clicking just below the radio button which is cell yes.

Selector for the Radio Button
<html title='FusionBanking' /> <webctrl id='_HiddenVector_SearchProductRs:searchProductsOutput:searchproduc*' name='_HiddenVector_SearchProductRs:searchProductsOutput:searchproduc*' tag='DIV' parentid='dojox_grid__View_3' tableCol='1' tableRow='1' idx='1' />

Yes it is Web application (Core Banking Application)


#10

Hi @thepathbreaker,

The selector like still table cell only not like radio button.

just add this one also from your selector and try again.
<webctrl tag='INPUT' type='radio' />

Regards,
Arivu


#11

Tried. There is no syntactical error.

it remains same.

There is no other attribute I can use because the only common value I am getting is idx


#12

Added
<html title='FusionBanking' /> <webctrl id='_HiddenVector_SearchProductRs:searchProductsOutput:searchproduc*' name='_HiddenVector_SearchProductRs:searchProductsOutput:searchproduc*' tag='INPUT' type='radio' parentid='dojox_grid__View_3' tableCol='1' tableRow='1' idx='4' />
Now it is stopped working with number (idx=‘4’) as well.


#13

try like this way
<html title='FusionBanking' /> <webctrl id='_HiddenVector_SearchProductRs:searchProductsOutput:searchproduc*' name='_HiddenVector_SearchProductRs:searchProductsOutput:searchproduc*' tag='DIV' parentid='dojox_grid__View_3' tableCol='1' tableRow='1' idx='1' /> <webctrl tag='INPUT' type='radio' />

Regards,
Arivu


#14

Same issue :frowning:


#15

Hi @Dominic & @arivu96

I have tried using dynamic selectors with other fields as well. Whenever I pass the variable, UiPath is not able to find the UI object. But if I use the exact value it is working as expected.

Is it because of the Studio version? I am using Studio 2017.1.6522


#16

Its working guys. Earlier I was ‘Indicating the screen’ and then changing the selectors.
I tried without ‘Indicating the screen’ and directly entered the selector copied from UiExplorer.

Thanks you both for quick replying and helping. :slight_smile: