Have you ever wished that you had different forms, not only for different kinds of users but for different situations? For example, if an issue's status is closed you'd like to require users to fill out the Resolution field. But in any other situation, they don't need to complete this field. In fact, until an issue's closed, users don't even need to see this field.
Quickbase's dynamic form rules allow you create forms that behave differently based on specific conditions. You set the condition and tell Quickbase what action (or actions) to perform using the Dynamic Form Rules tab when you're editing a form.
The following topics describe how dynamic form rules work and provide examples of different types of dynamic form rules:
About dynamic form rules
Rules that fire when a field is set to a value
Rules that fire for users in different roles
Rules that fire when a record is opened or saved
How Quickbase executes dynamic form rules
About dynamic form rules
When you write a form rule, you specify a condition that triggers a rule as well as the action that occurs after the rule is triggered. On the Dynamic Form Rules tab, you set the condition in the When portion of the screen, and the resulting action in the Action section of the screen.
Setting up conditions
In the When section of the dynamic form rules screen, you define the condition for the rule. The condition is what triggers the rule and is made up of an element, an operator, and matching criteria. You can create conditions based on:

Condition element | Description |
|---|---|
Field values | Triggers the rule based on the value entered or selected in a particular field. |
The user | Triggers the rule based on the role of the user editing the form. |
The record | Specifies that the rule should be triggered either when the record is opened or when it is saved. |
Setting multiple or additional conditions
You can choose to set multiple conditions. In this case, Quickbase displays extra controls which let you set several conditions at once. When you choose multiple conditions, you can specify whether all or only some of the conditions must be met to trigger the action.
To apply additional conditions, select Add Condition on the upper right of the rule designer pane.
If you don't select Multiple Conditions, you can still set multiple conditions by selecting Add Condition on the upper right of the rule designer pane. When you do so, Quickbase lets you specify conditions that also must be met—in addition to the first condition.
About setting multiple conditions on a single element
When two or more dynamic form rules show or hide the same element, you should combine them into one rule, using the Multiple Conditions selection.
Why? When multiple rules show or hide the same element, later rules interfere with those that fire earlier. To work correctly, each form rule has an inverse statement that tells Quickbase what to do when a rule's conditions aren't met. When you create or select a rule, you can see this inverse in the Otherwise section just below Actions.
For example, if you were to create a rule that specifies:
When Package Type is Fragile, show the Special Handling section
you'd see that part of that rule is also:
When Package Type is not Fragile, hide the Special Handling section
That's fine until a second rule comes along. Say that a later rule reads:
When Package Type is Oversize, show the Special Handling section.
The "otherwise" portion of this rule specifies that:
When Package Type is not Oversize, hide the Special Handling section
So, if Package Type is Fragile when the second rule runs, Quickbase would hide the Special Handling section, even though that contradicts the first rule. The later rule has the last word and "word" is that Fragile is not Oversize.
Setting up actions
In the Actions section of the dynamic form rules screen, you define the action that occurs after the rule is triggered. You can choose to have the action affect single form elements or all elements at once. Available actions are:

About setting the change to action
When a rule fires, Quickbase can automatically change the value in a field. You can change a field's value to a blank value, to today's date, to the current user, or to some other value.
If you want to change the value to something other than a blank, the date, or the user, type the new value in the text box that appears when you select Change to. The data type you select should match the data type of the field you're changing. For example, if you're changing the value in a text field, type text in the text box.
About the display message action
When a rule fires, Quickbase can display a custom message. Message rules are useful for:
Displaying messages to users when a record opens or saves
Displaying messages when certain values are selected in a field
A message is always associated with a field. If you want the message to appear at the top of the form, associate it with the first field in the form.
Examples of dynamic form rules
Here are some common uses of dynamic form rules.
