Table of Contents

Method ConvertTo

Namespace
Alternet.UI
Assembly
Alternet.UI.Common.dll

ConvertTo(ITypeDescriptorContext, CultureInfo, object, Type)

ConvertTo - Attempt to convert a double to the given type

public override object ConvertTo(ITypeDescriptorContext typeDescriptorContext, CultureInfo cultureInfo, object value, Type destinationType)

Parameters

typeDescriptorContext ITypeDescriptorContext

The ITypeDescriptorContext for this call.

cultureInfo CultureInfo

The CultureInfo which is respected when converting.

value object

The double to convert.

destinationType Type

The type to which to convert the double.

Returns

object

The object which was constructed.

Exceptions

ArgumentNullException

An ArgumentNullException is thrown if the example object is null.

ArgumentException

An ArgumentException is thrown if the object is not null, or if the destinationType isn't one of the valid destination types.