03-15-2011, 10:10 PM
Hi
I've recently switched over from Selenium to QTP11 and am trying to get a script working using a XPATH
(/descendant::input[starts-with(@id,'uniqueid-')])[1]
The problem is the ID is uniquely generated each time so the above was an XPATH which worked in selenium to select the textfield I required. Changing the 1 to 2, then 3, etc to access other text fields.
I've been looking around and have seen QTP11 supports XPATH but I cannot find an example of how to implement this
Can anyone shed some light on this?
thanks
I've recently switched over from Selenium to QTP11 and am trying to get a script working using a XPATH
(/descendant::input[starts-with(@id,'uniqueid-')])[1]
The problem is the ID is uniquely generated each time so the above was an XPATH which worked in selenium to select the textfield I required. Changing the 1 to 2, then 3, etc to access other text fields.
I've been looking around and have seen QTP11 supports XPATH but I cannot find an example of how to implement this
Can anyone shed some light on this?
thanks