I know how to convert an enumerated type to an integer.
type TMyType = (mtFirst, mtSecond, mtThird); var ordValue:integer; enumValue:TMyType; ... or
You can cast the integer by typecasting it to the enumerated type:
ordValue := Ord(mtSecond); enumValue := TMyType(ordValue);