Chapter 5 - Workflows
Chapter 5 - Workflows
The Workflow Manager window displays a tree from which you can add workflows
and edit their properties (actions, order). You assemble and edit the workflows in
the Pulse Workflow Editor.
In this exercise, you will create a workflow that will start a mixing process on the
Production floor. The workflow will send commands to perform tasks in the logic
specified below. Then, you will create a Pulse Button Instrument that executes
the workflow.
1 Open 1sv1
4 tempValue=parameter 1 value
6 tempValue=parameter 2 value
7 Cv1= tempValue
8 Cv2= tempValue
9 Cv3= tempValue
Value - 1
Enabled - True
9 Click Edit and type the condition below that means that the "IF" condition is
true if the TankLevel Variable value is less then 50
int.Parse(((Afcon.Pcim.Client.Workflow.Actions.GetAdvisedItem)t
his.GetActivityByName("Tank1_Level")).Value) < 50
Name setOutputLowVal
AdvisedItem OWS|PCIM!tempVal
11 Double-click the Bind Property icon to connect the value field to the
workflow's Parameter1 field.
14 Insert a Set activity for the ELSE branch according to step 3 in the Workflow
logic - If tank1 level >=50, then tempValue=parameter 2 value. If the tanks
level is above 50, then set a temporary variable "tempVal" with a parameter's
value that we will define later in this exercise.
Name setOutputHighVal
AdvisedItem OWS|PCIM!tempVal
15 Double-click the Bind Property icon to connect the value field to the
workflow's Parameter2 field.
Value - ?getvalue(ows|pcim!tempVal)?
Value - ?getvalue(ows|pcim!tempVal)?
Value - ?getvalue(ows|pcim!tempVal)?
Value – 1
1 Open the Project Navigator pane to 1 In the Home ribbon, click Execute.
the Workflows mode. The Execute Workflow dialog box
opens.
2 Right-click the specific workflow
and click Execute Workflow. 2 Expand the Workflows folder,
select the workflow, and click
Execute.
-or-
-or-
Parameter 1 80
Parameter 2 30
7 Change the tank level value below and above 50 and notice how the workflow
reacts, according to the defined logic.
Add a Pulse Button instrument, which will execute the workflow, to the
production display.
Text Start
4 In the Actions Workflow tab, define the command to execute when the user
pushes the mouse button up. Click the … button to open the Actions Selector
and select the Workflows option. Choose the StartProcess workflow, type
the Parameter1 and Parameter 2 values and click OK.
In this exercise, you will create a workflow that will stop the mixing process that
was started by the previous workflow. This workflow will send commands to
perform tasks in the logic specified below. Then, you will create a Pulse Button
Instrument that executes the workflow.
1 Close sv1
2 Close Cv1
3 Close Cv2
4 Close Cv3
5 Stop Mixer
2 In the Workflow Manager Window, right-click and click New Workflow. The
Pulse Workflow Editor opens.
Value - 0
Value – 0
Value – 0
Value – 0
Value - 0
Add a Pulse Button instrument, which will stop the workflow, to the production
display.
Text Stop
4 In the Actions Workflow tab, define the command to execute when the user
pushes the mouse button up. Click the … button to open the Actions Selector
and select the Workflows option. Choose the StopProcess workflow and click
OK.