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

Make Field on Form Required Based on Previous Field's Answer

Jump to solution

I have a list with two columns.

 

Column A is a required choice column. The choices are Yes, No.

Column B is a single line of text column. It is not required.

 

If a user selects Yes from Column A, then Column B should remain not required.

If a user selects No from Column A, then Column B should become required to have text in the text box.

 

How can I accomplish this?

 

I tried to set a validation rule on my text box control that says (ColumnA =="No"), which works BUT when i then enter text in the box, it still treats it as not being satisfied. I need a rule to say if ColumnA == "No" and if the feild is empty. Is  that possible?

Labels: (3)
0 Kudos
Reply
11 Replies
fhunth
Nintex Newbie

Re: Make Field on Form Required Based on Previous Field's Answer

Jump to solution

I think that you must base your rule on a calculated field setting on the formula your 2 conditions.

0 Kudos
Reply
mmatsako
Nintex Newbie

Re: Make Field on Form Required Based on Previous Field's Answer

Jump to solution

Yes this is possible using validation rules.  Make sure you are using Named Controls in your rule and not Item Properties when referring to ColumnA.

0 Kudos
Reply
koolgeex
Nintex Newbie

Re: Make Field on Form Required Based on Previous Field's Answer

Jump to solution

I'm not sure what you mean. Can you provide an example?

0 Kudos
Reply
koolgeex
Nintex Newbie

Re: Make Field on Form Required Based on Previous Field's Answer

Jump to solution

Yes - I was using the Named Controls when i tried my first validation rule. Do you have an example of the condition that would accomplish this using a Validation rule?

0 Kudos
Reply
mmatsako
Nintex Newbie

Re: Make Field on Form Required Based on Previous Field's Answer

Jump to solution

Ok, what version of Nintex are you using?  On-prem or O365.  Version number will be good too in case of a bug.

Thanks

0 Kudos
Reply
koolgeex
Nintex Newbie

Re: Make Field on Form Required Based on Previous Field's Answer

Jump to solution

On-Prem, Nintex Forms 2010 v1.6.1.0

0 Kudos
Reply
mmatsako
Nintex Newbie

Re: Make Field on Form Required Based on Previous Field's Answer

Jump to solution

Here is the rule that you need without the second part you will always get invalid:

 

ColumnA == "No" && isNullOrEmpty({Self})

Reply
mmatsako
Nintex Newbie

Re: Make Field on Form Required Based on Previous Field's Answer

Jump to solution

PS: {Self} is a variable found under Named Controls and refers to the control the rule is sitting on. In this case the textbox.

0 Kudos
Reply
koolgeex
Nintex Newbie

Re: Make Field on Form Required Based on Previous Field's Answer

Jump to solution

Yes that's it! Of course i tried to use isNullOrEmpty before but I didn't but the "{Self} call in there. Thank you so much!

0 Kudos
Reply