"Rethrow" Activity

Created by akaBot Support, Modified on Fri, 13 Dec, 2024 at 5:25 PM by akaBot Support

Introducing the "Rethrow" activity.


You can make use of a user guide to help a user get a complete understanding of a feature or a product. For example, this is how a user guide might look for using article template


TABLE OF CONTENTS

  1. Program name of the activity
  2. Description
  3. Properties
  4. Usage

1. Program name of the activity


System.Activities.Statements.Rethrow


2. Descripotion


Up to Studio version 2.0.2.0


Quick Access: "Toolbox" > "Error Handling" > "Rethrow"


From Studio version 2.0.3.0


Quick Access: "Toolbox" > "System" > "Error Handling" > "Rethrow"


This activity is used to rethrow an exception caught in the Catches block of a "Try Catch" activity. It can only be used within the Catches block of "Try Catch."


Tested akaBot Studio version: 2.2.0.5

Note: Wording or behavior may vary depending on the version.


3. Properties


Property item
Property name
InputDescription
OtherPublicCheckbox

When checked, the activity's variables and arguments are logged to the log file and pushed to the Center. (For details, see "About the 'Public' Property Item")

Display nameAnyString

Reflected as the activity name in the Designer panel.


4. Usage


Here, we've previously demonstrated how to use the "Throw" activity to throw an exception if the "

Welcome to akaBot Support!" element on the akaBot support portal site cannot be found. Now, we'll extend this example by introducing the use of a Catches block to catch this exception and re-throw it.


Note: We’ll be using the workflow created with the "Throw" activity. For more details, please refer to the knowledge base entry on "Throw".



First, open the Catches block and delete the existing Write Line activity.

Next, drag and drop the System > Error Handling > Rethrow activity into the Catches block.

Then, drag and drop a System > Originals > Write Line activity into the Finally block.

In the Text property under Miscellaneous, specify a string or String type variable (e.g., "Run workflow").
Refer to the "Creating Variables" guide for details on variable creation.

Close the support portal and execute the workflow by clicking Home > Start or pressing F5.

When the element "Welcome to akaBot Support!" is not found, a "Runtime execution error" dialog box will appear. Click "OK."

Open the output panel and verify the displayed contents. Since the exception is rethrown in the Catches block, the Finally block is not executed, and "Run workflow" is not displayed.


Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article