ScriptObject.ConvertTo Method (Type, Boolean)

Silverlight

Converts the current scriptable object to a specified type, with serialization support.

Namespace:  System.Windows.Browser
Assembly:  System.Windows.Browser (in System.Windows.Browser.dll)

'Declaration
Protected Friend Overridable Function ConvertTo ( _
	targetType As Type, _
	allowSerialization As Boolean _
) As Object

Parameters

targetType
Type: System.Type
The type to convert the current scriptable object to.
allowSerialization
Type: System.Boolean
A flag which enables the current scriptable object to be serialized.

Return Value

Type: System.Object
An object of type targetType.

ExceptionCondition
ArgumentException

The conversion failed or is not supported.

Silverlight

Supported in: 5, 4, 3

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

Community Additions

ADD
Show: