10-17-2012, 12:55 AM
Hi,
You can modify the code like this:
Thanks
Anurag
You can modify the code like this:
Code:
Browser("Link Express - Booking").Page("Link Express - Booking").Link("Booking").Click
Browser("Link Express - Booking").Page("Link Express - Booking").Link("Create").Click
Browser("Link Express - Booking").Page("Link Express - Booking").WebElement("FMCG Food and Drink Drink").Highlight
Set odesc=Description.Create
odesc("micclass").value="WebElement"
odesc("html tag").value="SPAN"
odesc("class").value="rtPlus"
Set val= Browser("Link Express - Booking").Page("Link Express - Booking").WebElement("FMCG Food and Drink Drink").ChildObjects(odesc)
Msgbox val.count
For i=0 to val.count-50
val(i).highlight
val(i).click
'a=val(i).GetROProperty("innertext")
'Msgbox a
Set odesc1=Description.Create
odesc1("micclass").value="WebElement"
odesc1("html tag").value="SPAN"
odesc1("class").value="rtIn"
Set val1= Browser("Link Express - Booking").Page("Link Express - Booking").WebElement("FMCG Food and Drink Drink").ChildObjects(odesc1)
Msgbox val1.count
For j=0 to val1.count-270
a=val1( j ).GetROProperty("innertext")
Msgbox a
val1(j).Highlight
Ifa="Beer"Then
Msgbox "Beer"
Val1(j).click
[undefined=undefined] var=1[/undefined]
Exit For
else
Msgbox "Failed"
End If
Next
[undefined=undefined]If var=1 then
Exit For
End if[/undefined]
Next
Thanks
Anurag