public override bool CanConvertFrom(
ITypeDescriptorContext context,
Type sourceType){
return true;
}
public override object ConvertFrom(
ITypeDescriptorContext context,
System.Globalization.CultureInfo culture,
object value){
return new TypeCunstomer() { Name = value.ToString() };
}
}
public class TypeObject{
public TypeCunstomer Name { get; set; }
}
public class TypeCunstomer{
public string Name { get; set; }
}