expected and actual values in message of Validate.Attribute : Automation API

expected and actual values in message of Validate.Attribute

Class library usage, coding and language questions.

expected and actual values in message of Validate.Attribute

Postby slavikf » Tue Apr 05, 2011 7:03 pm

I saw following in 3.0.1 description:
- Added placeholders for expected and actual values in message of Validate.Attribute methods

So, is there any documentation available for that? Or is it for the future?

Also, when i look at existing documentation:
http://www.ranorex.com/Documentation/Ranorex-2.0/
It says 2.0 in URL. Do you have other documentation for 3.0? Where?
User avatar
slavikf
 
Posts: 97
Joined: Mon Sep 13, 2010 10:07 pm
Location: Toronto, Canada

Re: expected and actual values in message of Validate.Attribute

Postby slavikf » Tue Apr 05, 2011 7:21 pm

Found here (at the bottom of the page):
http://www.ranorex.com/Documentation/Ra ... lidate.htm

You can use the following variables in messages you pass to the Validate methods that are replaced by the following values depending on the result of the validation:
Variable Value if validation succeeds Value if validation fails
"@ValidateRESULT@"
"succeeded"
"failed"
"@ValidateNOT@"
""
"not "
"@ValidateTRUENOT@"
"not "
""

For example, the following message will be transformed according to the outcome of the validation:

bool condition = true;
Validate.IsTrue(condition, "The validation @ValidateRESULT@.");
User avatar
slavikf
 
Posts: 97
Joined: Mon Sep 13, 2010 10:07 pm
Location: Toronto, Canada

Re: expected and actual values in message of Validate.Attribute

Postby Support Team » Tue Apr 05, 2011 7:31 pm

slavikf wrote:http://www.ranorex.com/Documentation/Ranorex-2.0/
It says 2.0 in URL. Do you have other documentation for 3.0? Where?

We used the same URL for backwards compatibility, it always points to the latest Ranorex API documentation. We will probably add a URL rewrite without a version number in it :D

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


Return to Automation API

Who is online

Users browsing this forum: No registered users and 0 guests