how do find current links in webpage for ex: in
yahoowebsite today mainpage is having 50 links and next day
same page is having 60 links. if i run same programe it
should display total links in webpage ?
Answers were Sorted based on User's Feedback
Answer / badri
Above script for weblists
To count No of Links in webpage:
Set chobj=description.Create
chobj("micclass").value="Link"
Set obj=Browser(" ").Page(" ").ChildObjects(chobj)
'Count the no of objects
n=obj.count
msgbox "No of Links: "&n
| Is This Answer Correct ? | 11 Yes | 0 No |
Set oDesc = Description.Create()
oDesc("micclass").Value = "WebList"
Set Lists = Browser("Mercury Interactive").Page("Mercury
Interactive").ChildObjects(oDesc)
NumberOfLists = Lists.Count()
| Is This Answer Correct ? | 2 Yes | 1 No |
Answer / u v r murthy
By using Page Check point also we could find out the total
link which are available in that particualr page.
Procedure: insert Standard check point then select any
object in the page, you will get Object selections popup,
there u can select page object, again you will get one more
popup called "Page Check point properties" in this popup
make sure that u have selected Links check box under ALl
OBJECTS IN PAGE then click ok.
Finally run the script. you will get the no of links
available in current used page in result window
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / sudheerreddym
Set link obj=description.Create
linkobj("micclass").value="link"
Set link childobjs=browser("Yahoo").Page("Yahoo").chldobjects(linkobj)childcount=link childobjs.Count
for i=0 to child Count-1
msgbox link childobjs(i).getRoproperty("innertext")
next
if u want to click on the last link on that page:
browser("Yahoo").page("Yahoo").link(index:="&childCount-1).cclick
set linkobj=nothing
| Is This Answer Correct ? | 0 Yes | 0 No |
What is the process of synchronizing qtp and aut?
Is there any pdf or online book for QTP Scripting? Let me know more about QTP Scripting.
It is given in the help of QTP 9.2 that we cant debug the scripts. Is there any other way to VIEW, PAUSE and make modifications in the scripts during execution???
Pls can anyone give me the descriptive programing script to find the number of edit boxes in a login window in flights reservation (windows application only not web). Pls anyone, very urgent
Tell me few important difference Between QTP and WinRunner?
Qtp Automation Engineer , Can he login in VSS? What purpose he login In VSS? But Some companys are using CVS AND VSS ? some are Have log in in VSS Some Not login(not accessing) into VSS, not login persons are working on CVS? my doubt is, can Qtp automation engineer have loin in VSS or not? Where he store QTp Script?
PLZ EXPLAIN HOW TO LAUNCHING QTP IN TEST DIRECTOR? Is it possible or not? If No Why we r using qtp Td Combination? plz explain briefly? What is the purpose of TD With QTP?
1--How many functions u develop 2--What is an array 3-- where is ur server 4--U involved in unit testing 5--how ur test the background colour using QTP
Excepton Handling?
Is it possible to change the name of a test object. I mean when we are recording the script for an object (for Ex: Username is a text field which has value "Babu",i am recording that). Then the Name of the object will become "Babu" in object repository. If i want to change "babu" as "xxxxx" .. is it possible to do? Pls help me in this .. if you didn't understand the question, pls let me know.
How Does Run time data (Parameterization) is handled in QTP?
How to Upgrade or support firefox 2.0 version on QTP 9.0? I have installed QTP 9.0 and installed firefox 2.0. But in REcord and Run Settings, it shows firefox 1.5 in Web tab for browser selection.