How to check if element isn't shown? : Object Identification and Technologies

How to check if element isn't shown?

Technology specific object identification, supported applications, web technologies, and 3rd party controls.

How to check if element isn't shown?

Postby WajdaW » Wed Jun 01, 2011 7:03 pm

I have situation where I need to check if element isn't found.
It comes to my mind to Search for this element and catch TimeOutException
try
{
FindSingle(element, timeout);
}
catch
{
// element isn't there
}

So is this only way or is there some better way to do this?

regards,

Vladimir Vajda
WajdaW
 
Posts: 72
Joined: Wed Jan 05, 2011 7:45 pm

Re: How to check if element isn't shown?

Postby Support Team » Wed Jun 01, 2011 8:48 pm

Hello Vladimir,

there is

validate.NotExists()


which internally does exactly that.

Regards,
Roland
Ranorex Support Team
User avatar
Support Team
Site Admin
 
Posts: 4845
Joined: Fri Jul 07, 2006 5:30 pm
Location: Graz, Austria

Re: How to check if element isn't shown?

Postby WajdaW » Thu Jun 02, 2011 11:38 am

Thanks, Roland.

Regards,

Vladimir Vajda
WajdaW
 
Posts: 72
Joined: Wed Jan 05, 2011 7:45 pm


Return to Object Identification and Technologies

Who is online

Users browsing this forum: No registered users and 0 guests