cancel
Showing results for 
Search instead for 
Did you mean: 
andrewg
Nintex Newbie

Quick Reference of Form Validations and Expression Operators

The condition that will mark the control as invalid and prevent the form from being submitted if the condition expression evaluates to TRUE. If the expression evaluates to FALSE, the rule will not be triggered. The formula builder button (to the right of the Condition field) can be used to aid construction of condition formulas. The form will not be submitted if the validation rule evaluates to TRUE.

To use an expression that needs an operator, use from the following:

String literals must be contained in double quotes (e.g. Option=="High").

== is equal to

=== is exactly equal to (value and type)

!= is not equal

!== is not equal (neither value or type)

> is greater than

< is less than

>= is greater than or equal to

<= is less than or equal to

&& and

| | or

! not

Use the {Self} variable (available in the Named Controls tab in the Formula Builder) to reference the value in control associated to a rule within a condition

If comparing two date controls you can (DateControl1 <= DateControl2) this is to mean that DateControl1 must be greater in order to be valid and allow submit.

Labels: (2)
Reply
17 Replies
Community Manager Community Manager
Community Manager

Re: Quick Reference of Form Validations and Expression Operators

Andrew,

Can't say how valuable this post has been.  Thanks for putting it together. I've referenced it in at least 3 answers so far. 

Reply
brad_orluk
Nintex Newbie

Re: Quick Reference of Form Validations and Expression Operators

I agree with Eric Harris​, this has been incredibly valuable.  Thank you Andrew Glasser​ for adding this to the community! 

0 Kudos
Reply
Not applicable

Re: Quick Reference of Form Validations and Expression Operators

This has been very helpful, thank you!

Reply
rickbakker
Nintex Newbie

Re: Quick Reference of Form Validations and Expression Operators

There can be issues with Nintex Mobile when using these operators. Please check this post: https://community.nintex.com/community/tech-blog/blog/2016/09/06/nintex-mobile-runtime-rules-work-on...

I therefor advice to use the default runtime functions where possible.

Cheers,

Rick

0 Kudos
Reply
karenp
Nintex Newbie

Re: Quick Reference of Form Validations and Expression Operators

How can a flag a numerical value that is out of range and prompt and additional response within the form?  For example, the value for a particular response should be between 7.7 – 8.3. If it’s not, I need the person to enter a corrective action.  I can’t figure out how to write the expression.

0 Kudos
Reply
andrewg
Nintex Newbie

Re: Quick Reference of Form Validations and Expression Operators

Try (ValueControl < 7.7) && (ValueControl > 8.3). Then this means the validation rule is invalid if not between 7.7 and 8.3 inclusive. When invalid, the user will be alerted to the issue and cannot submit.

0 Kudos
Reply
karenp
Nintex Newbie

Re: Quick Reference of Form Validations and Expression Operators

Thank you. A caveat is that I need for them to submit the value even if it’s out of range. We need documentation of the original value and corrective action. Is it possible to set up a flagged event (even simple, like text color) that would alert us that it is out of range?

Karen Pregnall, EdD, CT(ASCP), HTL(ASCP)

Lab Education Coordinator, Pathology and Lab Medicine

Adjunct Assistant Professor, Dept. of Health Studies

Medical University of South Carolina

843-792-4013

0 Kudos
Reply
andrewg
Nintex Newbie

Re: Quick Reference of Form Validations and Expression Operators

Oh yes absolutely, simply use a formatting rule instead of a validation rule. Add the rule to the appropriate control and have the background color change to Red when invalid.

0 Kudos
Reply
lotus222
Nintex Newbie

Re: Quick Reference of Form Validations and Expression Operators

How do I use AND function with more than two boolean conditions?

Formula Builder

and(isNullOrEmpty({Self}),not(isNullOrEmpty({ItemPropertySmiley Tonguere_x002d_Proposed_x0020_P7_x002})),greaterThan(PlannedP7Date,{ItemPropertySmiley Tonguere_x002d_Proposed_x0020_P7_x002}))
0 Kudos
Reply