Xpath to determine checkbox "checked" attribute in Selenium IDE

Viewed 43529

How to determine if a checkbox is check or not through xpath

Currently I am trying :

//input[@type='checkbox' and @checked='true')]

I have multiple checkboxes with same ids so I have to select the next checkbox which is not selected/checked.

Specifically I need this for Selenium IDE

Edit what I actually need is sth like :

|storeXpathCount | //input[@name='xyz' and @checked='checked'] | is_checked | 

if checkbox 'xyz' is checked , is_checked value should be 1 else 0

thanks

5 Answers
Related