Browser Exist taking ~3-4 mins to execute
Has anyone experienced a delay of about 3-4 minutes when trying to verify existence of any element (even Browser) when on any specific page?
If I open any other page(like google.com) in same browser in same machine (Win 7 with IE8), same statement takes about 3-5 seconds to execute?
Statement: msgbox Browser("title).exist(2)
I tried this in other machines as well but it is happening in other machines as well.
Tried in Firefox using Firefox addin and it is working better in Firefox.
I thought of some questions that may be useful to know.
Does the .exist(2) eventually return the correct answer? What does it do if you pick an object in the OR that is not on the screen? Does it also take a long time to give an answer? Does changing the time to wait for an object to exist in settings make a difference? Are you setting Enable Smart Identification True/False? Does using a DP description make it any better?
Yes. It returns the correct answer.
I did not check for object that is not present on the screen as just checking for Browser.exist is taking time.
Can you please let me know, which settings are you referring to by "change the time to wait in settings"?
using DP is not making any difference.
I will check Smart Identification thing and post here.
Under File/Settings/Run/Object synchronizatin timeout.
The value I have and I think it is the default is 20 seconds.
I'm asking because I am thinking if you have this set much higher that it will wait a maximum of this amount of time when the object is not there. I'm not sure if this is added to the amount of time in the .exist() statement. I get confused from the difference in the rules between WinRunner and QTP.
I'm asking these questions to look for a clue. I'm not really on to any one idea about what the delay could be.
Originally Posted by guptavijay
I guess this might be an issue with your page or other third party toolbars / addons that you might have on IE 8. Note this works perfectly fine with Firefox.
When you open 'this page' [i.e the page in which you encounter this issue] manually, how long does it take to fully load. May be some elements in your page are taking time to load. I had experienced some issues with pages, where the data was fed from Streaming servers. If you find something odd, take it to your developers.
You could also try disabling all addons, with the exception of BHO Manager Addon, and check if that helps.
Thanks bklabel1 and Rajkumar. I have neither set Object Synchronization Time OR any other setting in QTP to any value other than default value. None of the third party add on is the cause of this issue as shown below.
I tried below combinations and recorded the time taken in each case:
Add Ons Enabled 2:22
Add Ons Disabled 2:20
With OST: 0 and BNT:60 2:01
With BNT: 0 and OST: 20 :24
With BNT: 0 and OST: 10 :11
Both Settings: 0 Instant
Note that in each case, browser was loaded completely so there is no case of "waiting for object to synchronize or appear". Can someone please let me know, why the time taken depends on OST setting when BNT is set to 0 (there is no browser navigation happening)?
BNT: Browser Navigation Timeout
OST: Object Synchronization Time
Tags for this Thread