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

Validation Formula Help

Hello! I am creating required rules for questions on a Nintex Form. There are 6 flows for the form. The line where I am having an issue is in the Member/Marketing/Community Org. flow. When Someone selects MMCO and then for ProjectJobType they select Advertisement the Mass Media question that was previously hidden now shows and should be required. Similarly when someone selects the call or text Automated OUtreach, the formerly hidden question about the TCPA form shows and should be required.   In the below formulas it is successfully flagging as required and is able to determine if the question is completed to move on, but, if someone selects any other job type (than those 3) the Mass Media question and TCPA form questions are still required. Please help!

Whattypeofjobareyousubmitting=='Member/Marketing/Community Org.'&&ProjectJobType!='Advertisment'&&MassMediaType==''

DidYouFillOutTheTCPAForm==''&&ProjectJobType!='Automated Outreach - Outgoing Call Script'||ProjectJobType!='Automated Outreach - Text'

Labels: (1)
Tags (1)
0 Kudos
Reply
10 Replies
Automation Master
Automation Master

Re: Validation Formula Help

first of all, replace expressions that checks for empty strings with IsNullOrEmpty() runtime function

eg: Whattypeofjobareyousubmitting=='Member/Marketing/Community Org.'&&ProjectJobType!='Advertisment'&&IsNullOrEmpty(MassMediaType)

the second, use braces to force evaluation priority.

in your second formula I have feeling OR should be evaluated first, but the way the formula is written AND is evaluated first.

let us us know how it is going on when you correct these

0 Kudos
Reply
goodplans4us
Nintex Newbie

Re: Validation Formula Help

Marian Hatalathank you. I changed my 1st formula from

Whattypeofjobareyousubmitting=='Member/Marketing/Community Org.'&&ProjectJobType!='Advertisment'&&MassMediaType==''
to
Whattypeofjobareyousubmitting=='Member/Marketing/Community Org.'&&ProjectJobType!='Advertisment'&&IsNullOrEmpty(MassMediaType)

but it didn't change the outcome; it recognizes it as being required when Advertising is chosen but holds up other job types where it is not needed.
For the 2nd one when you say braces are you talking about parentheses? 1st I tried just switching the AND and OR statements without adding parentheses. This way it still recognizes it as being required but still holds up other job types that don't need this question answered..

ProjectJobType!='Automated Outreach - Outgoing Call Script'||ProjectJobType!='Automated Outreach - Text'&&DidYouFillOutTheTCPAForm==''
Then I tried the formula builder with the parentheses which I will admit is very confusing and it wouldn't surprise if I did it wrong

or(equals(ProjectJobType,'Automated Outreach - Text),equals(ProjectJobType,'Automated Outreach - Outgoing Call Script'))and(isNullOrEmpty(DidYouFillOutTheTCPAForm))
and this way it doesn't recognize it as begin required.

0 Kudos
Reply
Automation Master
Automation Master

Re: Validation Formula Help

Hi Jennifer,

One easy method of helping to troubleshoot this issue is to break your problem into parts and test accordingly... By this I mean take your rule and test the individual pieces to make they are all working...   So you will perform 3 separate tests at first:

Whattypeofjobareyousubmitting=='Member/Marketing/Community Org.'

ProjectJobType!='Advertisment'

MassMediaType==''

Once you have made sure these are working independently, then you can start tacking on the next rule to see if it works as combined

Whattypeofjobareyousubmitting=='Member/Marketing/Community Org.' && ProjectJobType!='Advertisment'

This should help reveal where the problem is.

Thanks

Mike

0 Kudos
Reply
Automation Master
Automation Master

Re: Validation Formula Help

PS:  Test permutations against the rule as well... for the first test:   First select the value that would cause your rule to be true and cause validation.  Then choose another value to make sure it works when rule is intended to result in false.    

0 Kudos
Reply
goodplans4us
Nintex Newbie

Re: Validation Formula Help

The 1st problem is with the 1st part - Whattypeofjobareyousubmitting=='Member/Marketing/Community Org.'.
!= doesn't recognize it as being required and
== recognizes it as being required but doesn't recognize when it is completed.
I don't know how to fix that part
The same is happening with the 2nd part - ProjectJobType!='Advertisment'

!= doesn't recognize it as being required and
== recognizes it as being required but doesn't recognize when it is completed.

The 3rd part - MassMediaType=='' - works as expected without other criteria but of course it block all other flows.

0 Kudos
Reply
Automation Master
Automation Master

Re: Validation Formula Help

Hi Jennifer,

Spelling and space characters will count - I noticed that in your reply Advertisment was spelled wrong--- missing the "e" after the s - it must match the choice exactly in the field.   Please double check your rule for that.   Also, please put a space before and after != and ==   if you don't already have them.  Ive seen rules go wonky before due to spacing.   Lastly, the special characters "/" and "." in your first rule may be causing this to fail.   Can you choose another value and see if your rule fires correctly.   I believe there has been problems with special characters but I've I can't quite recall if that's true or not (too many versions and too many forms but i seem to remember something going wrong with them before).

Thanks

Mike

0 Kudos
Reply
goodplans4us
Nintex Newbie

Re: Validation Formula Help

Mike Matsako‌ Thank you. I feel bad that I am finally getting back to this. I changed the 1st part of my rule from equals to contains so I get rid of the /s in my formula and it worked.

contains(Whattypeofjobareyousubmitting,'Member')&& ProjectJobType != 'Advertisement' && MassMediaType == ''

Reply
goodplans4us
Nintex Newbie

Re: Validation Formula Help

Mike Matsako‌ Thank you again, using contains rather than equals so I don't have to use /s helped.

‌ Thank you. Using the formula builder and all the parentheses sometimes makes my formulas really confusing but sometimes I can mix the use the shortcuts and formula builder. Using your suggestion of the null or empty runtime was the last trick to make this work.

contains(Whattypeofjobareyousubmitting,'Member') && contains(ProjectJobType,'Automated') && isNullOrEmpty(DidYouFillOutTheTCPAForm)

Reply
goodplans4us
Nintex Newbie

Re: Validation Formula Help

I guess I didn't test the mass media formula all the way though because it held up other types of jobs.I had to use contains instead of != or == but I guess all that matters is that it works in the end

contains(Whattypeofjobareyousubmitting,'Member') && contains(ProjectJobType,'Advertisement')  && isNullOrEmpty(MassMediaType)

Reply