based on search keyword in anysearch site say google ...
trying to retrieve the total number of links present in that webpage and Check all the links in that web page .
i have used the below code for this but getting error saying "expected expression" in line numbers 4,9,10,17,19
mainly i think line 4 is wrong ...
can anyone pls correct me ...
Thanks
Navya
trying to retrieve the total number of links present in that webpage and Check all the links in that web page .
i have used the below code for this but getting error saying "expected expression" in line numbers 4,9,10,17,19
Code:
Browser("google").Page("google").WebEdit("what").Set "plumbers"
Browser("google").Page("google").Image("btnG").Click 32,22
Set oDesc = Description.Create()
[b] oDesc(”html tag”).Value = "A"[/b]
Set rc = Browser("google").Page("google").ChildObjects(oDesc)
lnknum = rc.Count()
For j =0 to lnknum-1
Set rc = Browser("google").Page("google").ChildObjects(oDesc)
[b]tag = rc(j).GetROProperty(”innertext”)[/b]
[b]href = rc(j).GetROProperty(”href”)[/b]
Browser("google").Page("google").link(""&tag).click
Browser("google").navigate(href)
Browser("google").Page(""&tag).Sync
Browser("google").Back
'check if the navigated page is equivalent to targetted page
[b]orgPage =Browser("google").GetROProperty(”innertext”)[/b]
If tag = orgPage Then
[b]Reporter.ReportEvent 0, “Navigated To Correct Page”,""&tag 'Reports if correct [/b]
else
Reporter.ReportEvent 1,""&tag,""&orgPage
End If
next
mainly i think line 4 is wrong ...
can anyone pls correct me ...
Thanks
Navya