System.ComponentModel.CharConverter.ConvertTo C# (CSharp) Method

ConvertTo() public method

public ConvertTo ( ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType ) : object
context ITypeDescriptorContext
culture CultureInfo
value object
destinationType Type
return object
		public override object ConvertTo(ITypeDescriptorContext context, CultureInfo culture, object value, Type destinationType) 
		{
			if (destinationType == typeof(string) && value is char)
			{
				if ((char)value == (char)0)
				{
					return "";
				}
			}
            
			return base.ConvertTo(context, culture, value, destinationType);
		}