ExpressionServices.TryConvertReference<TResult> Method

Definition

Converts a reference to a workflow environment-aware expression to an activity tree.

C#
public static bool TryConvertReference<TResult>(System.Linq.Expressions.Expression<Func<System.Activities.ActivityContext,TResult>> expression, out System.Activities.Activity<System.Activities.Location<TResult>> result);

Type Parameters

TResult

The type the expression is being converted to.

Parameters

expression
Expression<Func<ActivityContext,TResult>>

The expression being converted.

result
Activity<Location<TResult>>

The converted expression.

Returns

true if the expression can be converted; otherwise, false.

Remarks

The conversion methods in ExpressionServices are designed to work with variables and constants defined inside the workflow, or passed into the workflow via arguments.

Applies to

Proizvod Verzije
.NET Framework 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1