SyntaxFix
Write A Post
Hire A Developer
Questions
check out System.Enum.Parse:
enum Colors {Red, Green, Blue} // your code: Colors color = (Colors)System.Enum.Parse(typeof(Colors), "Green");