Skip to main content
Nintex Community Menu Bar

Validation rule on all fields/controls in Panel

  • July 23, 2017
  • 6 replies
  • 22 views

Forum|alt.badge.img+3

Hello All,

I have a Panel containing 10 fields, I would like to know if it is possible to make them all mandatory based on a number of possibilities from a drop down list.

For example, If dropdown has a value of A or B then all fields in the panel are mandatory

Any thoughts?

Thanks

6 replies

Forum|alt.badge.img+14
  • Scholar
  • July 23, 2017

yes you can achieve what you ask for.

select all the controls you want to validation for and 'Add new rule' for them.

or if you already have the rule created use 'Assign rulle to selected control' option to apply it to further controls.

for exact form of validation formula it's important to know whether dropdown control is backed by a choice or lookup control type.


Forum|alt.badge.img+3
  • Author
  • July 24, 2017

Thanks Marian.

The problem with doing that from what I can see with my limited knowledge, it that it can get a little messy. Each rule would be different to reference that field. For example

isNullOrEmpty(Field1) && (DROPDOWN=="A" || DROPDOWN=="B")
isNullOrEmpty(Field2) && (DROPDOWN=="A" || DROPDOWN=="B")
isNullOrEmpty(Field3) && (DROPDOWN=="A" || DROPDOWN=="B")

etc.

Unless I am missing something.

Thanks


Forum|alt.badge.img+14
  • Scholar
  • July 24, 2017

at the end of 'Named controls' list there is a {Self} reference which is replaced with actual value of control a rule is being evaluated on

205849_pastedImage_1.png

so you should be able to buil single formula like

isNullOrEmpty({Self}) && (DROPDOWN=="A" || DROPDOWN=="B")

Forum|alt.badge.img+3
  • Author
  • July 24, 2017

Excellent, thank you Marian. Feel free to take the rest of the day off ☺


Forum|alt.badge.img+14
  • Scholar
  • July 24, 2017

if it worked for you please mark correct answer.

the day off would be fine, but I'm not so lucky happy.png


Forum|alt.badge.img+14
  • Scholar
  • July 24, 2017

could you mark as correct my above post with a solution to your original question?

that helps other users with the same question/problem to find correct answer quickly.

thanks.