IBM BPM, V8.0.1, All platforms > Create processes in IBM Process Designer > Modeling processes > Create a business process definition (BPD) > Configure conditional activities

Manage conditional activities by using the JavaScript API

You can find and select conditional activities for runtime execution by using the following JavaScript API properties.

The following table lists the available JavaScript API properties.

JavaScript API properties
Property Description
tw.system.process.conditionalActivities Finds all conditional activities in a process definition (BPD). Returns a list of items of the ConditionalActivity variable type. You can use this property to construct a Coach that specifies the conditional activities that you want to run in the current BPD instance. The conditional activity sample available in [AppServer_HOME]\BPM\Lombardi\imports\conditional-activity-sample.twx includes a Coach that demonstrates this type of implementation.
tw.system.process.selectedConditionalActivities Returns a list of identifiers for the conditional activities that are to be run at run time. You can set the value of this property by providing a list of conditional activity IDs to be selected. This property also accepts a comma-separated string of IDs, which is the output format from the conditional activity Coach described earlier.
tw.system.step.isConditionalActivitySelected Determines wheter the current step is a conditional activity that is selected for execution.
tw.system.process.guid Returns the ID of the BPD.
tw.system.step.guid Returns the ID of the step or activity that is currently running.

Configure conditional activities