Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to identify top browser from a lot of browsers?
#11
Hi guocnc,

Why are you going to calculate all browsers..? in Same browser you are clicking link 3.

No need to count the all browsers and Sreekanth provided solution is works fine.
Reply
#12
Thanks for MVChowdary,

There is some hidden condition in the solution. CreationTime:=0 means the frist open browser. If there are some browsers in desktop, how do we know which browser is currently working? And after executing Links(3).click, the browser should be at the top of a list of browsers. So we should count all the browsers in order to identify the top browser. If we can use other system way to identify top browser, then maybe it is another solution.
Reply
#13
Here it is very simple......... in for loop it starts (0) first browser to (browco-1) recent browser.... you can get any info about any browser on desktop by using below code and just modify as per your requirement

Code:
Dim bro Set bro=description.Create bro("micclass").value="Browser" Set brow=desktop.ChildObjects(bro) browco=brow.count print browco For i=0 to browco-1 ind=brow(i).getroproperty("text") print ind Next
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Running test with multiple browsers mvi63 0 3,136 06-25-2014, 06:49 PM
Last Post: mvi63
  Cannot find the "[ WebEdit ]" object's parent "[ Browser ]" (class Browser). Verify t Divya Roopa 1 9,156 03-11-2014, 12:13 PM
Last Post: devarapallliramana
Rolleyes QTP 11 not identify PDF Browser laxminaranaya 1 2,868 02-25-2014, 01:34 PM
Last Post: guin.anirban
  Multiple 2 IE browsers are being displayed VA1405 1 2,367 01-15-2014, 07:20 AM
Last Post: basanth27
  Will Object Property Differ across browsers?? qtplearner88 7 5,069 07-30-2013, 07:18 PM
Last Post: qtplearner88

Forum Jump:


Users browsing this thread: 1 Guest(s)