Export (0) Print
Expand All

14. Enums

Visual Studio .NET 2003

An enum type is a distinct value type (Section 4.1) that declares a set of named constants.

The example

enum Color
{
   Red,
   Green,
   Blue
}

declares an enum type named Color with members Red, Green, and Blue.

Show:
© 2014 Microsoft