Cast <T> Activity


An activity that casts a value to a specified type and assigns it to a variable or argument.

Inheritance Hierarchy:



This activity allows you to cast an object of a particular type into a different type and assign it to a variable or argument.

In a Workflow:

A cast is a programming term that refers to the explicit conversion of an object of one data type to another type. You would use this activity to cast a variable value to a different type and assign it to a different variable. This activity is similar to the Assign activity, but in addition, it allows you to perform the desired type conversion operation.

For a cast to be valid, the Value must be convertible to the type of the To variable otherwise an System.InvalidCastException will be thrown.


Name Description

In Arguments


The value to cast and assign to the To variable or argument.


Display Name


You can change the name of an activity to one that describes what it does. A descriptive name can make a workflow easier to interpret and maintain.

Out Arguments


The variable or argument to assign the casted value to.

Version Information:

Supported from: Geocortex Essentials 3.7.

For more information: