Blank or Whitespace validation

  • 22 January 2018
  • 2 replies
  • 3 views

Badge +3

Hi,

I have a mandatory Text field with the following validation rule formula.

Visitor1=='' && (isNullOrEmpty(trim((Visitor1FirstName))||Visitor1FirstName =='') && (Visitor1LastName!='' || Visitor1Organisation!='')

The validation should work like this: if the drop down (Visitor1) is not selected then Visitor1FirstName and Visitor1LastName and Visitor1Organisation should not be empty. [See below Image]Validation fields

It work perfectly, if the these three fields were empty when Visitor1 is not selected. However, if a space was entered to any of these fields, somehow it ticketed the blank space as a value and bypass the validation.

So how to validate the blank or whitespace in Nintex form Text field?

Thanks,

Emily


2 replies

Badge +16

can you add trim to all three textboxes in your rule?

Badge +5

Did you ever get this to work? I am having the same problem, REFERENCE:  

The TRIM worked but only some of the time. I am not sure what made it work sometimes and then not others. As a test today I removed the TRIM from one of the choices to see if the behavior changed and it did, the validation itself now work vs working in a very odd way. It would accept 1/2 of the form filled in and let the second 1/2 bypass and let the form save. It was as if the section were separate. 

Reply