Workflow Tutorial: Handling Exceptions
This tutorial (another in our infamous series) helps users to understand how exceptions are handled by using an ExceptionTrigger component and a DivideValues component.
So, get your components together and dive in!
Prerequisites: None
Objective: To learn exception handling.
Estimated time to complete: 30 minutes
Step 1: Create a new Decision Only project.
Step 2: Drag and drop the ExceptionTrigger component from the Infrastructure / Exceptions category.
Drag and drop the DivideValues component from the Math category.
Duplicate the End component and link the components as shown below:
Step 3: Set the Input Data as shown below:
Step 4: Set the Output Data as shown below:
Step 5: Right click on the DivideValues component and select Edit Component. Click the selector button next to the First Value field and click the Add button under the Variable Data tab. Select 'value1'.
Step 6: In the same way, set the Second Value to 'value2'. Set the Output Variable Name to 'retValue' by typing in the text box.
Step 7: Right click on the End component which is connected to the ExceptionTrigger component and select Edit Component.
Select the Value from Data radio button and click on the selector button. Select 'ExceptionTriggerMessage' as the variable name.
Step 8: Right click on the End component connected to the Divide Values component. Click the selector button next to the Mapping field and select the Value from Data radio button. Select 'retValue' as the variable.
Step 9: Save and Run the project. Click Run project on the tool bar (bug with green arrow over it).
Step 10: Double click Execute and set the input values. Click OK.
Step 11: The results are shown as below:
Step 12: Execute the project again and set the input values as shown below:
Step 13: The results are shown as below:
Step 14: Finished!
- Login or register to post comments
- 1998 reads
- Printer-friendly version



























Error Handling
This is very important to have error handling built-in to workflows so that when the user does not enter correct data, or the wrong type of values are entered that it can be corrected without breaking the application.