Get all the members values of an enum

suggest change
enum MyEnum
{
    One,
    Two,
    Three
}

foreach(MyEnum e in Enum.GetValues(typeof(MyEnum)))
Console.WriteLine(e);

This will print:

One
Two
Three

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents