[]
        
(Showing Draft Content)

C1.WPF.Extended.WebColor.ToColor

ToColor Method

ToColor(string)

Convert a hex string to a .NET Color object.

Declaration
public static Color ToColor(string hexColor)
Parameters
Type Name Description
string hexColor

A hex string: "FFFFFF", "#000000"

Returns
Type Description
Color

ToColor(string, byte)

Convert a hex string to a .NET Color object.

Declaration
public static Color ToColor(string hexColor, byte alpha)
Parameters
Type Name Description
string hexColor

A hex string: "FFFFFF", "#000000"

byte alpha

Represents the alpha channel of the color.

Returns
Type Description
Color