Pls anyone, tell me the script in QTP to find the number of
links, and images in a webpage. Verry very urgent. I
shall really be very thankful

Answers were Sorted based on User's Feedback



Pls anyone, tell me the script in QTP to find the number of links, and images in a webpage. Verry..

Answer / hemakumar.m

'For Links
Dim oLinkDes
Set oLinkDes=Description.Create()
oLinkDes("micclass").value="Link"
a=Browser("title:=.*").Page("title:=.*").Childobjects
(oLinkDes).Count()
Msgbox a

'For Images
Dim oImageDes
Set oImageDes=Description.Create()
oImageDes("micclass").value="Image"
a=Browser("title:=.*").Page("title:=.*").Childobjects
(oImageDes).Count()
Msgbox a

Is This Answer Correct ?    9 Yes 0 No

Pls anyone, tell me the script in QTP to find the number of links, and images in a webpage. Verry..

Answer / hemakumar.m

oLinkDes=Description.Create()
oLinkDes("micclass").value="Link"
a=Browser("title:=.*").Page("title:=.*").Childobject
(oLinkDes).Count
Msgbox a

oImageDes=Description.Create()
oImageDes("micclass").value="Image"
a=Browser("title:=.*").Page("title:=.*").Childobject
(oImageDes).Count
Msgbox a

Is This Answer Correct ?    7 Yes 0 No

Pls anyone, tell me the script in QTP to find the number of links, and images in a webpage. Verry..

Answer / guru

You use Page checkpoint

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

how do pass parameters from one action to another action

2 Answers  


Who is the best faculty for QTP in Hyderabad? Is it Mr. G.C.Reddy, some are referring his name?

21 Answers  


Does quicktest professional (qtp) is unicode compatible?

0 Answers  


What are main panes available in qtp test browser?

0 Answers  


waht is the diff b/w Environment variable and Global variable in qtp?? explain types of variable in qtp??

5 Answers  






How you create new action in qtp?

0 Answers  


four browser are open same application i want to enter 3browser how?

3 Answers   IBM,


Can any one explain me what is the procedure to connect the remote desk by using QTP 9.2 ?

0 Answers   IGI,


How to handle "Java Runtime error" popup window in the web application ? Sometimes the application throws the error repeatedly... Is there any browser setting available to disable the error ?

2 Answers   TCS,


Suppose one object is changed in a project after delivering the project.Where we will update that object? it can be present in many scripts so can we update all the scripts?

1 Answers   IBM,


HOW AUTOMATE TEST SCRIPT ? what time it will do? after gneration of basic script or Any , Plz explain detailed?

0 Answers   Wipro,


How can I check if a environment variable exist or not?

0 Answers  


Categories