Switch
Runs the case that matches the value of an expression; if none matches, the Default section runs. The type of the expression is selected in the Select Switch Type window that opens when the activity is added (default String).
⬅️INPUT
Parameter | Type | Required | Description |
|---|---|---|---|
|
| ✅ Yes | Expression whose value is compared with the cases. Its type is the selected type. In the designer it is the Expression field. |
Usage
The activity has the following fields, from top to bottom:
Expression: The expression whose value is compared.
Case: Each case has a value and activities. Added with the Add Case (+) button, deleted with the Delete button, reordered by dragging. For
Booleanand enum types the value is selected from a list; for other types it is typed. A case whose value is left empty causes a validation error; two cases cannot have the same value.Default: Activities that run when the value of the expression matches no case.
The value of the expression is compared exactly with the case values (case-sensitive for text). Only the matching case runs; if there is no match and Default is empty, nothing runs.