If 3 browsers are opened in our system, how to enter the
facebook url into second browser by using descriptive
programing
Answer Posted / sireesha
'Open a new Browser
SystemUtil.Run "iexplore.exe", "http://www.google.com"
'Browser Sync
Browser("CreationTime:=0").Sync
'Find total number of tabs in the browser window
iTabs = Browser("CreationTime:=0").GetROProperty("number of tabs")
msgbox iTabs 'Displays the value 1
'Open a new tab within the same browser
Browser("CreationTime:=0").OpenNewTab()
'Sync for new tab
Browser("CreationTime:=1").Sync
'Load some web page in the new tab
Browser("CreationTime:=1").Navigate "http://www.yahoo.com"
'Find total number of tabs in the browser window
iTabs = Browser("CreationTime:=0").GetROProperty("number of tabs")
msgbox iTabs 'Displays the value 2
'Close all the tabs in the browser window
Browser("CreationTime:=0").CloseAllTabs()
'OR -> Browser("CreationTime:=1").CloseAllTabs()
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
how to fetch the values from grid? & qtp recogniges that grid as a webelement? what u do?
Can we create user defined functions in qtp?
what r the main attributes of test automation?
What are the types of object repositories? Which one is you using?
How do I lauch my test website using code from qtp in different environmet, uat and PPTE?
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 are the disadvantages of recording test cases in qtp?
What is smart identification in QTP?
Hi Friends this is kumar i would like to request to all of you ,please help me to explain real time project with using qtp scripts i know basics of qtp but it won't workout on interviews,pls help awating to reply.
What is a checkpoint? How many check points are there in qtp?
How to execute the WR Script through QTP? I have WinRunner script with initialization script, common scripts, GUI AND functions. I connected WR through QTP with "call to WinRunner" option but I am getting problem after connecting to WinRunner i.e. showing "Do you want to quit now" with 'yes' and 'No' message box
Hi Every body please explain me in steps to use checkpoints and object Repositories in QTP for Flight Reservation application please tell me the steps for this its urgent pls thanx for urs answers
How to interact tool & application build in QTP?
How many types of recording modes in qtp?
What is the use of ordinal identifier in qtp?