How can I get the number of items defined in an enum?
You can use Enum.GetNames to return an IEnumerable of values in your enum and then .Count the resulting IEnumerable.
GetNames produces much the same result as GetValues but is faster.