Skip to main content

Example on How to use Scope

Written by Ossi Galkin

A Scope Element groups other Elements together. The Scope works the same way as scopes denoted by { and } in C#. For example, variables declared inside are not visible outside, and any exception thrown within the Scope is caught by a Catch Element attached to the Scope Element.

The return value of a Scope is the same as that of the Return Element.

In the example below, the Scope would be used for error handling, as the Catch Element below the Scope would catch any error that happens in the Tasks (Task A or Task B) within the Scope.

The next article is Introduction to documentation.

Did this answer your question?