Convert ole Color To Color - CSharp System.Drawing

CSharp examples for System.Drawing:Color Convert

Description

Convert ole Color To Color

Demo Code

// Permission is hereby granted, free of charge, to any person obtaining a copy of this
using System.Windows.Media;
using System;//w w w.  j  a  va2  s.c  o m

public class Main{
    public static Color ConvertToColor(uint oleColor)
      {
         System.Drawing.Color color = System.Drawing.ColorTranslator.FromOle((int)oleColor);
         return (Color)ColorConverter.ConvertFromString(color.Name);
      }
}

Related Tutorials