How to get Links count in an web application,without
descriptive programming?
Answer Posted / a
POSTED BY -CHAITU
This Script is Helpfull to count the No.of links in a web
page
Step1: Set Objects = Browser("BrowserName").Page
("PageName").ChildObjects
Step2: Objectcount = Objects.count
Linkcount = 0
Step3: For i = 1 to Objectcount-1
Link = Objects(i).GetROProperty("micclass")
If Link = "Link" Then
Linkcount = Linkcount+1
msgbox Linkcount
End If
Next
msgbox Linkcount ' It show total number links
--------------
This code is not working.
Check it out.
Link = Objec(i).GetROProperty("micclass")
Error is here.
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
how do we know whether all objects are stored in the object repository or not? how can we know if a particular object is not stored in the repository?
How will you test a stapler?
hi can any body give me a script for creating a modularity or keyword driven framework..i am working as a qtp tester for 2 months but still i am not exposed to framework in my company
What is the Difference between copy to action and call to action?
What is a checkpoint? How many check points are there in qtp?
Have you done batch testing in qtp? If yes how you are doing?
Does QTP10 supports Windows 7OS +IE 9 combination? Which is the preffered combination ,Plz let me know?
I need to obtain the parent of an object programatically, so if I have: winButton("aButton") I need to obtain the parent part: window("Window1").Dialog("Dialog1") so I can programatically create a string of the full name of the object to call it with an execute statement in QTP I would like to use something like: part[1] = "window(""Window1"")" part[2] = "dialog(""Dialog1"")" so I can do: exeLine = part[1]&"."&part[2]&"."&"winButton(""aButton"")" Execute exeLine Apart from keeping a record of the window/dialog hierarchy is there a parent or path function/ command Thanks Adrian
How the exception handling can be done using quicktest professional (qtp)?
How can I open a EXCEL file from QTP Resultviewer with reporter.ReportEvent function call. Example: Test files for details click "here". And clicking "Here" in the resultviewer will open a local EXCEL FILE.
What is the difference between the design-time and run-time data tables?
Define Environment Variable in UFT and its uses?
How can i initiate the objects to find uniquely in OR
What are the different types of functions available in qtp and explain ?
Any body have QTP 9.5 licence key. please provide me at madhukar_dec30@yahoo.co.in