Method ConvertTo
ConvertTo(ITypeDescriptorContext, CultureInfo, object, Type)
Converts the given value object to the specified type, using the specified context and culture information.
public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType)
Parameters
contextITypeDescriptorContextAn ITypeDescriptorContext that provides a format context.
cultureCultureInfoA CultureInfo. If null is passed, the current culture is assumed.
valueobjectThe Object to convert.
destinationTypeTypeThe Type to convert the
valueparameter to.
Returns
Exceptions
- ArgumentNullException
The
destinationTypeparameter is null.- NotSupportedException
The conversion cannot be performed.