EnableRule Action

The EnableRule() action allows a rule to run. When you use this action in a Then or Else expression, a rule can enable a rule. Only enabled rules can run. You can disable a rule with the DisableRule action.

Note: Do not use this action to immediately enable subsequent rules in the queue. If EnableRule is configured to enable a subsequent rule, that rule does not run if currently disabled and is not enabled until the trigger message defined for this rule causes the rule to be reevaluated.

If a rule is recursive or violates execution policy, the Platform disables it. In this situation, this action fails. Make sure that the rule you are attempting to enable is not recursive and does not violate execution policy.

Format:

EnableRule(String ruleName)

where ruleName is the name of the rule that you want to enable.

Example:

The following example enables the rule called Rule456. If no rule of this name exists, the action is ignored. If Rule456 was disabled by the Platform, this action fails. If Rule 456 is already enabled, this action is ignored.

Then/Else: EnableRule("Rule456")