How to select a radiobutton in a WebTable

586 views
Skip to first unread message

Narin

unread,
Feb 24, 2014, 8:56:46 AM2/24/14
to seleniu...@googlegroups.com
Hi,

Can someone help me with the idea to select a RadioButton in a WebTable. I am able to navigate till that point but i am not able to select the radio based on the Row,Col.

<div>
<table id="ctl00_cpEndUserMain_ucOnwardJourney_gvServices" class="table-border-new" cellspacing="0" border="0" style="width:100%;border-collapse:collapse;border-collapse:separate;">
<tbody>
</tbody>
</table>
</div>

Thanks,
Narin
Radio_WebTable.png

Janusz Kowalczyk

unread,
Feb 24, 2014, 10:26:19 AM2/24/14
to seleniu...@googlegroups.com
Hi,

try using CSS nth-child selector:

ie: to select third row
tr:nth-child(3)


Cheers,
J

Fernando Anjala

unread,
Feb 24, 2014, 10:18:40 PM2/24/14
to seleniu...@googlegroups.com
HI Narin, 
Go through below Link, It might help ya to have a good understanding about working with radio buttons :)


Regards
Anjala fernando 

Oscar Rieken

unread,
Mar 2, 2014, 9:23:17 AM3/2/14
to seleniu...@googlegroups.com
not worth the headache of not knowing what you click, Add some i'ds to each row


--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To post to this group, send email to seleniu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/1f9e187b-140b-457b-8fc4-480865cf6d42%40googlegroups.com.

For more options, visit https://groups.google.com/groups/opt_out.

Saravanan Ravi

unread,
Mar 5, 2014, 8:32:04 AM3/5/14
to seleniu...@googlegroups.com
Please mention the path like this,
 
selenium.check("//table[@class="table-border-new"]/tbody/tr[1]") - To select first radio button
selenium.check("//table[@class="table-border-new"]/tbody/tr[3]") - To select third radio button
 
Regards,
Saravanan R
Reply all
Reply to author
Forward
0 new messages