Table of Contents

Method ConvertTo

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

ConvertTo(ITypeDescriptorContext?, CultureInfo?, object?, Type)

Converts the specified object to another type.

public override object? ConvertTo(ITypeDescriptorContext? context, CultureInfo? culture, object? value, Type destinationType)

Parameters

context ITypeDescriptorContext

A formatter context. Use this object to extract additional information about the environment from which this converter is being invoked. Always check whether this value is null. Also, properties on the context object may return null.

culture CultureInfo

A CultureInfo that specifies the culture to represent the color.

value object

The object to convert.

destinationType Type

The type to convert the object to.

Returns

object

An object representing the converted value.

Exceptions

ArgumentNullException

destinationType is null.

NotSupportedException

The conversion cannot be performed.