06-01-2009, 07:03 PM
Hi Everyone,
I need some help with writing a code to select links based on the html id. Problem is that in the application different links have different ids eg id_100987, id_200492, id_101492
And if I use id_.*then it picks up links which I don't want.
code I am using is:
This works as long as the id starts with html:=id_100 but I want QTP to click on all the links where html id starts with id_100, id_101 and id_200
Please help,
Thanks in advance
I need some help with writing a code to select links based on the html id. Problem is that in the application different links have different ids eg id_100987, id_200492, id_101492
And if I use id_.*then it picks up links which I don't want.
code I am using is:
Code:
strSS=Browser(B).Page(P).WebElement("html id:=id_100.*", "index:=0").GetROProperty("innertext")
MsgBox strSS
This works as long as the id starts with html:=id_100 but I want QTP to click on all the links where html id starts with id_100, id_101 and id_200
Please help,
Thanks in advance