A
Adrian
Coding a website, one can create RGB colors with three pairs of two-digit
hexadecimal values.
How can one do that in C#?
Many thanks.
hexadecimal values.
How can one do that in C#?
Many thanks.
Nicholas Paldino said:Adrian,
Yes, you can, but the thing is, what are you trying to do?
Dennis Myrén said:System.Drawing.Color c = System.Drawing.Color.FromArgb( /* R */ 0xFF, /* G
*/ 0xFF, /* B */ 0xFF);
You can convert a HTML style color string to System.Drawing.Color like this:
System.Drawing.Color c = System.Drawing.ColorTranslator.FromHtml("#FFFFFF");