How can we close all webbrowsers which are opened in out
desctop?

Answers were Sorted based on User's Feedback



How can we close all webbrowsers which are opened in out desctop?..

Answer / venu

The following code can be used in order to close all the IE
browsers:

SystemUtil.CloseProcessByName "IEXPLORE.EXE"

Is This Answer Correct ?    10 Yes 0 No

How can we close all webbrowsers which are opened in out desctop?..

Answer / meenakshisundharam

If browser(xxxx).Exist then
browser(xxxx).close
End if

Is This Answer Correct ?    9 Yes 0 No

How can we close all webbrowsers which are opened in out desctop?..

Answer / syam

While Browser("CreationTime:=0").Exist
Browser("CreationTime:=0").Close
Wend

QTP Tip1: The first browser that opens receives the
value "CreationTime" = 0, the second browser
receives "CreationTime" = 1, and so on...

Is This Answer Correct ?    4 Yes 0 No

How can we close all webbrowsers which are opened in out desctop?..

Answer / d.selvakumar

SystemUtil.CloseProcessByName "iexplore.exe"
pls use small letters

Is This Answer Correct ?    1 Yes 0 No

How can we close all webbrowsers which are opened in out desctop?..

Answer / chandrashekar reddy

there are 2 ways to close the all browsers in qtp
1) we can use while..... wend 2) we can use
description.create method

1) while Browser("index:=0").exist (1)
browser(index:=0).close
wend

2) set ab=description.create
ab("micclass").value="Browser"
set obj=Desktop.childobjects(ab)
b=obj.count
msgbox b
for i= 0 to b-1
names=obj(i).getroproperty("name")
msgbox name
obj(i).close

Is This Answer Correct ?    1 Yes 0 No

How can we close all webbrowsers which are opened in out desctop?..

Answer / ambadas

please give ans

Is This Answer Correct ?    0 Yes 0 No

How can we close all webbrowsers which are opened in out desctop?..

Answer / joseph

Tested in tool -
Answer 1 is right
Answer 3 is right
Answer 5(1) - Update (browser(index:=0).close) to browser("index:=0").close
Answer 5(2) - Need to include 'Next' for 'For' loop

Is This Answer Correct ?    0 Yes 0 No

How can we close all webbrowsers which are opened in out desctop?..

Answer / ram shankar

visit below URL, you can get qtp browsers scripts

http://www.gcreddy.com/2010/01/qtp-web-testing-scripts.html

Is This Answer Correct ?    0 Yes 2 No

Post New Answer

More QTP Interview Questions

Hi, Am trying to download QTP 8.2 version.its not supporting Windows Vista.Can you please help me out from this.Which QTP version supports this. Thanks in Advance.

2 Answers  


How do you return a value from a function

1 Answers  


what is spy, and how can u use?

1 Answers  


what is meant by "Parameterization technique"?

4 Answers   KH, Mind Tree,


what happen in object repository(shared)if we call an existing action from an external action ? and what happen in object repository(peraction)if we call an existing action from an external action ?

2 Answers  






What is different command used in command Prompt while using QTP?

0 Answers  


VB - Script Training in MUMBAI.

1 Answers  


Which object model is not supported by QTP? a)COM b)DECOM c)DOM d)DCOM. Pls explain about theese object models?

1 Answers  


Do we get any issues if we run the testscript on different browsers? what are the options we need to st in QTP?

2 Answers   BirlaSoft,


Can I compare two DataBases using QTP ?

1 Answers  


in login module login button chage regularly(means login button change to submit button).What is the code for it.

3 Answers  


Which is the best QTP training institute in Delhi/NCR region and what is the approximate fee for QTP course (Basics and Advanced)

0 Answers  


Categories