Hiding Controls With Rules in Nintex Forms

  • 15 February 2022
  • 0 replies
  • 2098 views

Userlevel 5
Badge +19

Topic

How can you hide particular controls based on condition within Nintex Forms?

 

Instructions

This tutorial is applicable to Nintex Forms 2016, Nintex Forms 2013 and Nintex Forms 2010.

 

 

 

This tutorial assumes that the user has basic knowledge of designing forms with Nintex Forms. If not, please refer to Getting Started with Nintex Forms.

 

Using Rules to hide a section of the form based on a checkbox

In this scenario, we have using a workshop registration form. We want to know if the person has any special dietary requirements, so we can cater for them. Once we have created the rule, the Dietary requirements panel, as shown below, will only display to the user when the Special diet required checkbox is selected. 

 

Note: To hide a section on the form, use the Panel control to group controls together. For more information refer to the Panel Control.

Name the Yes/No Control

This tutorial begins in the Nintex Forms designer, with a form I’ve already designed. The first step is to name the Special Diet Required, Yes/No control so we have a name we can use when creating the rule. This control will determine whether the Dietary Requirements panel will show on the form during runtime.

 

On the Yes/No control, right-click and select 'Settings' to open the settings dialog.

 

9847iD502EA8C9D6296C1.png

 

In the Name field, enter “Special diet required” and click Save.

 

9848i8A92F2E059697019.png

 

The control has now become a named control.

 

Use Rules to hide/show the Special Dietary Requirements panel control

The next step is to create the rule. This panel will remain hidden unless the user selects the Special diet required checkbox. To open the Rules pane, click on Rules in the Ribbon.

 

9850iE1850E1FC88B073E.png

 

Select the Panel control and then click on Add New Rule. We can now configure the rule. In the Name field, call the rule “Show if special diet".

 

9852i9513E9E371AAEC34.png

 

In the Condition field, click on the formula builder, f(x), button.

 

9854i9737AF696BA93C8F.png

 

Click on the Runtime Functions tab and double-click on the function not. Click on the Named Controls tab and double-click on Special diet required. The formula should look like this: = not(Special diet required ). Click OK.

 

9855i58FB8351BEA88528.png

  

Note: Conditions must be expressed as a formula that will result in a TRUE value for the rule to be applied.

 

9856iA89A55594ABDFE15.png

 

Finally, check the Hide box on the Rules panel.

 

9857i574C25AF2117EA99.png

 

Now when the Yes/No control is unchecked, this formula will evaluate to TRUE and the panel will be hidden. There is no need to save the rule, it is ready to use straight away.

 

The form is now ready to be published.

 


0 replies

Be the first to reply!

Reply