public static Array GetValues(Type enumType) { List<object> tempList = new List<object>(); foreach (var x in enumType.GetFields()) { if (x.IsLiteral) { tempList.Add(x); } } return tempList.ToArray(); }