7.6 Condition Activity

The Condition activity lets you add conditional logic to a workflow. This logic can be used to control what happens when the workflow executes. In the Condition activity, you define logic as an ECMA expression that evaluates to a Boolean value.

Each Condition activity must have two outgoing flow paths, one that handles conditions that evaluate to True and another that handles conditions that evaluate to False. Optionally, a third flow path can be added to handle error conditions that occur if the ECMA expression evaluation fails.

7.6.1 Properties

The Condition activity has the following properties:

Table 7-14 Condition Activity Properties

Property Name



Provides a name for the activity.

Condition Expression

Specifies an ECMA expression that returns True or False. The value returned determines which flow path is followed after the activity has finished executing.

HINT:If you need to test whether two objects are equal in a conditional expression, you should use the == operator, rather than the equals() method, unless you are certain that the objects being compared are Java objects of the same type. For instance, use this expression:

(approval_A.getAction() == "DENIED")

instead of this one:


For details on building ECMA expressions, see Section 9.0, Working with ECMA Expressions. For descriptions of the system variables available in a workflow, see Section 6.5.3, Understanding Workflow Data.

7.6.2 Data Item Mapping

Not supported with this activity.

7.6.3 E-Mail Notification

Not supported with this activity.