GetEnumName( ) method
- Last Updated: January 18, 2024
- 1 minute read
- OpenEdge
- Version 12.8
- Documentation
Returns the name of the enumeration member associated with the specified numeric value. The
method returns an error if invoked on a type that is not an enumeration or if passed the
Unknown value (?).
Return type: CHARACTER
Access: PUBLIC
Applies to: Progress.Lang.Class class
Syntax
|
- value
- The underlying numeric value of an enum member. If no member is defined for the value,
the method returns the Unknown value (
?).
Notes
- For a flag enum instance that represents multiple flags set, the method returns a
comma-separated list of members, unless there is a member that is explicitly defined as a
combination of those members. For example, for the
Permissionenum type shown below, specifying the value 3 would return "ReadWrite" instead of "Read,Write".ENUM Permission FLAGS: DEFINE ENUM None = 0 Read = 0x01 Write = 0x02 Update = 0x02 ReadWrite = 0x03 Create = 0x04 Delete = 0x08. END ENUM. - If the enum type defines multiple members for the same value, as the
Permissionenum type above does forWriteandUpdate, the method returns one of the member names, but there is no guarantee as to which one will be returned.