public enum PaymentType
{
Unknown = 0,
Points = 1,
Comps = 2,
Promo = 3,
Cash = 4,
UnPaid = 5
}
public static List<string> paymentTypes = null;
if (paymentTypes == null)
{
List<PaymentType> paymentValues = Enum.GetValues(typeof(PaymentType)).Cast<PaymentType>().ToList<PaymentType>();
paymentTypes = new List<string>();
foreach (var item in paymentValues)
{
paymentTypes.Add(item.ToString());
}
}
Now check output in paymentTypes object.
0 comments:
Post a Comment