several browsers opened. write QTP script to close all browsers except gmail.



several browsers opened. write QTP script to close all browsers except gmail...

Answer / puspita

Dim d
Set d=Description.Create
d("micclass").value="Browser"
Set a=Desktop.ChildObjects(d)
For i=0 to a.count-1
s=a(i).GetROProperty("title")
If instr(1,s,"Gmail")=0 Then
a(i).Close
End If
Next

Is This Answer Correct ?    22 Yes 1 No

Post New Answer

More QTP Interview Questions

What will be the test script in QTP to test a ComboBox where a user has to select more than two items????

8 Answers   L&T,


Whether it is possible to test the adobe's controls like zoom, resize, save etc using QTP...If yes, how u can do the same?

1 Answers  


1. wat are the main diff b/w QTP 8.0 AND QTP 9.2 ( not user interface) 2. wat is the meaning of Keyword in keyword driven frame work? 3. how u will handle the unknown errors while exucution. (not recovery scenario)

0 Answers   HCL,


I have application it is one digital clock with all minutes and seconds. you have to identify the time to verify weather the time displayed is correct time or not? How do you automate this scenario?

2 Answers   TCS,


How many types of trigger events are there in qtp?

0 Answers  






in my system object spy show the web application as a window based propeties ex:winedit like that and also not recording scripts also so what should i do

2 Answers  


How to switch between browser tabs? )moving from one tab to another tab)

1 Answers   CTS,


hi friends i have 4 yrs exp in testing and 2 yrsexp in QTP.currently aim working in mnc in north as a permanent employer .iam looking for job in south is there any openings plz let me know my mail id is bjr@aol.in its very urjent

5 Answers  


For Data-Driven testing can you use micro soft word document instead of using Datatable what is your approach?

0 Answers   Nokia,


How can i click on any Excel sheet's "H" column with out writing coordinates Ex:Window("Book1").WinObject("Book1").Click 498,14 I dont want to give coordinates like 498,14 Can i open "H" column by writing like Ex:Window("Book1").WinObject("Book1").Click "H" or Ex:Window("Book1").WinObject("Book1").Click "H","1" or Ex:Window("Book1").WinObject("Book1").Click H,1 If i want to click on "Sheet3" of an excel sheet, Can i open like Ex:Window("Book1").WinObject("Book1").Click "Sheet3" Please help me any one

0 Answers   Livetek,


What is the XML file architecture ?

0 Answers  


What are different types of frame works ?

3 Answers  


Categories