Enum.Parse converts a string to an enum.
It accepts the enum type and a string that can include multiple members:
using System;
using System.Numerics;
enum WeekDay
{
Monday, Tuesday, Wednesday, Thursday, Friday
}
class Sample
{
public static void Main()
{
WeekDay w = (WeekDay)Enum.Parse(typeof(WeekDay), "Monday, Tuesday");
}
}