Create Declare OnChange rules to run an activity automatically at activity step boundaries when the value of a specified property changes. This capability provides a form of automatic forward chaining.
The following tabs are available on this form:
For example, a Declare OnChange rule can update a year-to-date counter property (an integer) to track how many times a work item status changed in value. Another Declare OnChange rule can compute the average dollar amount of work items entered by a team, in real time.
Declare OnChange rules can force all processing on a work item to be suspended pending an independent review of the situation. The independent review is supported by one or more flows. This feature can support compliance, fraud detection, and quality control staffs.
No other rules explicitly reference Declare OnChange rules. After you save a Declare OnChange rule, it is run immediately and as needed.
Use the Application Explorer to access OnChange rules that apply to work types in your application. Use the Records Explorer to list all OnChange rules available to you.
Declare OnChange rules are instances of the Rule-Declare-OnChange class. They are part of the Decision category.
- Declare OnChange rules -
- Declare OnChange form - Completing the OnChange Properties tab
Define the conditions that will cause this rule to be executed. Specify in an array the properties to be watched for change.
- Declare OnChange form - Completing the Pages & Classes tab
Use this tab to list the pages referenced by name in the OnChange tab. Specify the pages in an array containing these fields. See How to Complete a Pages & Classes tab for basic instructions.
- More about Declare OnChange rules
Pega Platform tracks properties listed in Declare OnChange rules for changed values. After each activity step, and after forward chaining for Declare Expression rules and constraints rules occurs, tracked changes start the activity specified on the OnChange Properties tab.
- How to implement business exception processing with policy overrides
Through OnChange rules and special flows, your application can create application-wide temporary pauses in flow processing — for example, to detect and review exceptions, suspect data or special cases — without altering the flows. This provides an alternative to use of tickets.