Can you give me the code to calculate the total number of
Links using the child object in the web page..? is there
any other way to calculate number of links with out using
the Child objects.??
Answers were Sorted based on User's Feedback
Answer / uday kumar_anem
Set fileSysObject=createobject("Scripting.FileSystemObject")
Set
linksFileName=fileSysObject.opentextfile("D:\samplelinkfile.txt",2,true)
Set linkDescObj=description.Create
linkDescObj("micclass").value="Link"
Set noOfLinks=browser("Browser").Page("Yahoo!
India").ChildObjects(linkDescObj)
For i=0 to noOfLinks.count-1
linkName=noOfLinks(i).getROProperty("name")
linksFileName.writeline(linkName)
Next
linksFileName.close
Set fileSysObject=nothing
Here i am retrieving all the links in Yahoo home page and
writing the link names in a text files.
If you wish to verify the number of links a web page, you
can use "Standard Checkpoint".
Click on Record button ->Insert Menu -> Check point
->Standard Checkpoint -> Click on any place in the page and
select the page in the Hirarchy and observe the number of
links property/value. If the total number of links are
increased or decreased, then it will show the differences.
| Is This Answer Correct ? | 2 Yes | 0 No |
how can i parameterize a login page by using database parameterization i fetch the username and password from database and put this on login page and click on ok button. so how can we write script for that code please let me know asap thanks
How can I replace all the text from the QTP script with some other text. Is there any replace all function in QTP Any one can help me
How to delete an object from the object repository?
What is the basic concept of quicktest professional (qtp)?
How to make Non reusable actions into reusable action? is that feature available in QTP
list me out the shortcutkeys for some functionlities in the qtp for example to record ,to run ... etc
how to get the data from a winedit box in vb scripting and store it in a variable if data contains "_"(i.e data is TEST_1)
How to Analyze the Checpoint results by Table and DB Checkpoints?
write the vb script for call to new action in qtp?
WHAT IS SMATR IDENTIFICATION? plz EXPLAIN BRIEFLY? IS IT POSSIBLE in QTP? HOW AND WHEn THE SITUATION U R USING EXPLAIN WITH EXAMPLE?
what skills needed to be good test automation?
How do client side image and server side image work?