Main Content

Display .NET Enumeration Members as Character Vectors

To get the descriptive name of an enumeration, use the char method. For example, type:

gameDay = System.DayOfWeek.Thursday;
['Next volleyball game is ',char(gameDay)]
ans =
Next volleyball game is Thursday