Get a name of enum value (Views: 101)
How can I retrieve the string name of some enumerate value?
For example, if you have the some enum type TyourEnumType = (One, Two, Three, Four, Five, Six, Seven, Eight, Nine, Ten) and you want in run-time to get a string with same value for each of them (for example, fill the combobox items with enum values), then you can use the next procedure:
for i := Ord(Low(TyourEnumType)) to Ord(High(TyourEnumType)) do
<< Back to main page