using System.Drawing
//顏色轉字串
Color color = Color.Red;
string strColor = ColorTranslator.ToHtml(color);
//字串轉顏色
string strColor = "#42f492";
Color color = ColorTranslator.FromHtml(strColor);
Last active
June 2, 2019 07:54
-
-
Save oddstab/472476db681cbb348c29dcbddc7c9598 to your computer and use it in GitHub Desktop.
C# 字串顏色互轉
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment