Posts Tagged ‘convert color’

Convert color to string

To convert a color to a string use the ColorConverter class but this can be access through TypeConverter class;

  1. Dim myColor as Drawing.Color = Color.Red
  2.  
  3. Dim clor As System.ComponentModel.TypeConverter = System.ComponentModel.TypeDescriptor.GetConverter(myColor)
  4. dim ColorName as string
  5.  
  6. ColorName = clor.ConvertToString(Color.Red)

, ,

1 Comment



SetPageWidth