How to get all descriptions of enum values with reflection?
So I need to get a List<string> from my enum Here is what I have done so far: enum definition [Flags] public enum ContractorType { [Description("Recipient")] RECIPIENT = 1, [Description("Deliver")] DELIVER = 2, [Description("Recipient / Deliver")] RECIPIENT_DELIVER = 4 } HelperClass with method to do what I need: public static class EnumUtils { public static IEnumerable<string> GetDescrptions(Type enumerator) { FieldInfo[] fi = enumerator.GetFields(); List<DescriptionAttribute> attributes = new List<DescriptionAttribute>(); foreach (var i in fi) { try { yield return attributes.Add((