Not applicable

## Hide/Show on multiple choices checkbox

Jump to solution

Choices menu have a choice options from 1 to 5, and Multiple checks are allowed, so what happened is, when I choose 1, it display 1 field, but when I choose 1 or some other option, let say 1 and 2, or any other choice, than it makes the condition false and 1 field disappear. Is there anyway I can display multiple fields and selection on the more than one value that does not make it disappear.

6 Replies
Scout

## Re: Hide/Show on multiple choices checkbox

Jump to solution

Your rule will work with this condition >>> not(contains(Choice,'1'))

Consider that the value of Choice when you select 1 and 2 , is [1,2] so you will need to know if 1 is contained on those choosen values.

Scholar

## Re: Hide/Show on multiple choices checkbox

Jump to solution

Thank you - this works perfectly.  Now I also need to take this one step further where I have, for example, selections of 1, 2, 3 by a multiple choice checkbox.  I need to be build for an OR condition where:

If the user selects 1, hide Next item; if the user selects 3, hide Next item. So if there is 1 at all, item hides.  If there is 3 at all, item hides.  Meaning [1], [1,2], [1,2,3], [3] all cause a hide.  [2] would not hide, but there are many more choices than this so I cannot specify this directly.

I believe I have a syntax problem because I have tried not(contains(Choice,'1'))||not(contains(Choice,'3')) and this does not work.  Can you show or explain where/how I need my OR (I'm using ||) should be for this set and is there a better way to indicate items not in a given set?

Nintex Employee

## Re: Hide/Show on multiple choices checkbox

Jump to solution
Hi,
The not() runtime function can only be used at the start of a formula to reverse the outcome. It cannot be embeded in a formula as you have used it. You may want to use the operation ! instead.
Scholar

## Re: Hide/Show on multiple choices checkbox

Jump to solution

I was able to solve this, (another example of AND vs OR and syntax issues.)

My resolution is:

not(contains(Choice,"Value"))&&not(contains(Choice,"Value"))&&not(contains(Choice,"Value"))

This worked like a charm for my multiple selection checkboxes and I will have other panels that use a similar formula.

Not applicable

## Re: Hide/Show on multiple choices checkbox

Jump to solution

Thanks Fernando for the answer

Not applicable

## Re: Hide/Show on multiple choices checkbox

Jump to solution

so just to be clear for someone looking for a same solution, as Fernando describe about the selected values, I was able to get the values from Choice Menu through the Calculated field, and that string you can match in the Contains action. I try to used Choice field control name as it is in the Contains action that didn't work so I used calculated field to get the choices and use that calculated field in the Not(Contain(cal, '1')) formula.

Thanks Fernando.