Support Article
Cannot use When rules as condition expression to disable button
SA-10330
Summary
When two When rules are used in an expression to disable a button, users cannot save the rule form because the page throws an error.
ERROR MESSAGE
Cells in a Row: [expression with two when rules] does not exist or it is not a valid value for this Ruleset and its prerequisites.
Steps to Reproduce
Configure two When rules as a Disable condition.
Actual: A button in a section has a Disable condition based on a single When rule
Expected:
1. Transform Disable Condition from When Rule to Expression.
2. Implement the desired expression that should be two When rules in OR.
3. After performing a Save operation, the Disable condition is well formatted as an expression.
4. When you save the Section rule, an error appears stating that the rule IsCancelled || !CreateCRMAContract does not exist or is not valid due to ruleset prerequisites.
5. Open the button properties and see that the Disable condition implemented (and saved) as an expression is now a When condition.
Root Cause
The root cause of this problem is a defect in Pegasystems’ code/rules. This issue is scheduled to be resolved in Pega 7.1.8 release.
However, heed the following caveats:
* For auto-generated sections, complex When expressions will be allowed and honored when “typed directly”. However, the Expression Builder will still allow only one operator.
b.For non-auto generated sections and JSP directives, the old limitation of 1 operator will still apply.
Resolution
This issue is resolved through the following local change as suggested by SA-4165 : A product enhancement for a future release will offer a When rule that includes the two conditions.
Published July 6, 2015 - Updated October 8, 2020
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.