write a script to close all open browser in qtp except one
browser whose name is xyz
Answer Posted / lak
dim oBrowser,oAllBrowser,nProcessId,nCounter
set oBrowser = Description.Create
oBrowser("micclass").vlaue="Browser"
set oAllBrowser = Desktop.childObjects(oBrowser)
for nCounter=0 to oAllBrowser.count-1
if(instr(oAllBrowser(nCounter).getRoProperty
("title"),"xyz"))<=0 then
nProcessId = oAllBrowser(nCounter).getRoProperty("process
id")
Systemutil.closeProcessById nProcessId
End if
else
oAllBrowser(nCounter).close
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
what is the difference between data driver & data driven and driver script?
How is the Bitmap checkpoint different from Image checkpoint?
In an interview, what r the general questions asked in SQL which is realted to testing ?pls give me anwser to this question?
what is clean sweep?
what is ODC and GDC?
What is an object repository?
Is it possible to split an action? How?
can i change the runtime properties of an object ? How can i check if a parameter exists in database ?
How to capture all the data of a webtable, weblist and combolist using QTP?
What is Cross browser testing? Does UFT support it?
hi, FOR 3+ QTP INTERVIEW, FOR EXAMPLE WE PUT ONLINE BANKING SYSTEM PROJECT IN OUR RESUME, IN PROJECT MANAGER ROUND...WHAT R THE MAJOR QUESTIONS ARE ASKED IN P.M? PLS TELL ME ATLEAST 10 QUESTIONS?.....AND IF POSSIBLE POST ANSWERS ALSO....
When to use descriptive programming?
For which type of projects the iterative model is not suitable?
How many tabs are available in debug viewer pane?
How to test the login page in different ways in automation testing and i need code?