Global wait time for Objects

Class library usage, coding and language questions.
jlowder
Posts: 55
Joined: Wed Dec 30, 2009 2:56 pm

Global wait time for Objects

Post by jlowder » Mon Jan 09, 2012 10:53 pm

Hello,

I'm developing all of my automation in Visual Studio and would like a means to increase the wait time for objects globally. I'm working with one particularly annoying dialog that varies in it's object load times and instead of adding a value at the end of every FindSingle, I'd like to add one "Global" value. Is this possible?

Thanks,

Jason

User avatar
Support Team
Site Admin
Site Admin
Posts: 12145
Joined: Fri Jul 07, 2006 4:30 pm
Location: Houston, Texas, USA
Contact:

Re: Global wait time for Objects

Post by Support Team » Tue Jan 10, 2012 1:32 pm

Hello,

You can use
Ranorex.Adapter.DefaultSearchTimeout = new Duration(yourDuration);
to set the default search timeout.
The timeout value set to this property is used for searching when implicitly casting a path (in its string representation) to an adapter variable like:
Button button = "pathToButton";
You can also use
Adapter.TimeoutFactor = 0.5;
to multiply all timeouts of find operations with the specific value.

Regards,
Markus
Ranorex Support Team