LambdaValue<TResult>.CanConvertToString Method (IValueSerializerContext)

.NET Framework (current version)
 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

This method always returns true and is used in conjunction with ConvertToString to provide descriptive error messages when an attempt is made to serialize this activity to XAML.

Namespace:   System.Activities.Expressions
Assembly:  System.Activities (in System.Activities.dll)

public bool CanConvertToString(
	IValueSerializerContext context
)

Parameters

context
Type: System.Windows.Markup.IValueSerializerContext

Context information that is used for conversion.

Return Value

Type: System.Boolean

This method always returns true.

LambdaValue<TResult> is used for lambda expressions specified in code and cannot be serialized to XAML. If an attempt to serialize a workflow that contains a LambdaValue<TResult> is made, a LambdaSerializationException is thrown. If the containing workflow requires XAML serialization, use VisualBasicValue<TResult> or use ExpressionServices to convert the LambdaValue<TResult> to a format that can be serialized.

.NET Framework
Available since 4.0
Return to top
Show: