A.I on the 1s and 0s

Alnur Ismail is a PM for Microsoft's XAML

Browse by Tags

All Tags » C# » Enum (RSS)
Sorry, but there are no more tags available to filter with.
C# - Iterating through an Enum
Today I came across a situation where iterating through an Enum would save me about 10 lines of code and some time. The quickest way is as follows: foreach (MyEnum value in Enum .GetValues( typeof (MyEnum))) { //... }
Posted: Oct 06 2008, 05:27 PM by alnurismail | with 6 comment(s)
Filed under: ,
More Posts