Skip to main content
Verify the version tags to ensure you are consuming the intended content or, complete the latest version.

Configuring dynamic behavior in forms

Depending on your business needs, you can mark form fields as required, disable them under certain circumstances, or hide them completely. 

For example, in a loan application you can mark the fields that contain the name and address of the applicant as being required fields. This ensures that users do not skip information when completing the form that is crucial to successfully processing the Case.

Configuring form field behavior

 To configure form field behavior:

  1. Open the View with the field that you want to configure.
  2. In the Edit view pane, click the Configure icon next to the field whose behavior you want to change. 
  3. In the Edit field dialog box, in the Conditions section, define the target behavior of the field: 
  • In the Required field, specify whether the field must be completed by the user.

  • In the Disabled field, specify when the field is visible but not available to users.  

  • In the Visibility field, define when the form should display the field. 

Configuring form field behavior
  1. To configure fields as Read-only at all times or only when specified conditions are met, click inside the Edit mode list and select an option, as shown in the following image:  
Configuring fields as read-only

 

Conditional form behavior

You can use Constellation to further define form behavior by creating Conditions and When Rules. Conditions and When Rules trigger specific form actions when certain conditions are met within a form.  

Conditions 

You can configure the visibility of form fields based on conditions that you set, using the Condition builder. For example, in a loan application, you can create a Condition that hides fields that collect information about a spouse if the customer is single. 

Learn more about creating Conditions in Constellation.  

When Rules 

When Rules evaluate a Boolean logic statement that involves comparisons among field values, to return true or false results. For example, you can create a When Rule that returns a true result if a job applicant has more than ten years of experience, and if the applicant speaks French fluently. As a result, an application performs a specific action, such as starting an optional application process in a Case. 

Learn more about creating When Rules in Constellation.  

Cascading drop-down lists

The cascading drop-down pattern occurs when a selection in one drop-down list affects the available values in subsequent drop-down lists. For example, when a user selects an industry in an Industry drop-down list, the system can automatically populate the available values in the Industry subcategory drop-down list based on the industry that the user selected.  

For example, in the image below, selecting Mining Division as a category automatically populates the subcategory drop-down list with subcategories from the mining industry. 

Cascading dropdown

Let’s look at a practical example of configuring a cascading drop-down list in the context of the Industry and Industry subcategory scenario. 

In this scenario, a Case’s Data Model contains a Data Page that returns a list of industries. In the Case’s Data Model, we define a picklist property to render the industries as a drop-down list, using our Data Page as a source and choosing the display field and identifier, as shown in the following image: 

Configuring cascading dropdowns in App Studio

The Data Model also contains a Data Page called LookupSICByIndustry, for fetching a list of subcategories based on the industry that is passed as a parameter. In the Case’s Data Model, we then define a picklist property to render the subcategories as a drop-down list. We bind the picklist property to the Data Page LookupSICByIndustry, as shown in the figure below. App Studio recognizes that LookupSICByIndustry takes a parameter, so in this way we can pass the industry property that we defined above.   

Configuring cascading dropdowns in App Studio

The entire end-to-end process is configured using App Studio, in the Case’s Data Model. This reduces development time and errors, improving consistency across the application stack. 

Check your knowledge with the following interaction:


This Topic is available in the following Module:

If you are having problems with your training, please review the Pega Academy Support FAQs.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Academy has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice