Progress.Util.EnumHelper class
- Last Updated: January 18, 2024
- 1 minute read
- OpenEdge
- Version 12.8
- Documentation
(Windows only; .NET)
A helper class that provides a set of static methods you can use to perform operations on .NET enumeration types in ABL.
Serializable:
No
Constructors
This class does not contain a constructor.
Super Class
This class does not inherit a super class.
Interfaces
This class does not implement interfaces (beyond those it inherits from its base class).
Public Properties
This class does not contain properties.
Public Methods
Public Events
This class does not contain events (beyond those it inherits from its base class).
Notes
- The functionality for all of the methods of this class, except for
Add( )andSubtract( ), can be accomplished for .NET enums using ABL operators (e.g., you can use GE or >= operator instead ofIsGreaterOrEqual( ), NOT operator (bitwise) instead ofComplement( ), etc.). These methods are still supported for backward compatibility. - Some
Progress.Util.EnumHelpermethods return aSystem.Enumclass instance. If you want to use the returnedSystem.Enuminstance as a different enumeration type, you must cast the instance to that specific type using the CAST function. For example:USING System.Windows.Forms.* FROM ASSEMBLY. USING Progress.Util.* FROM ASSEMBLY. DEFINE VARIABLE myButton AS Button. DEFINE VARIABLE myStyle AS System.Enum. myButton = NEW Button(). myStyle = EnumHelper:Or( AnchorStyles:Bottom, AnchorStyles:Right ). myButton:Anchor = CAST( myStyle, AnchorStyles ). /* Displays "Bottom, Right" */ DISPLAY STRING( myButton:Anchor ) FORMAT "x(20)". - For information on the
System.Enumclass and .NET enumeration types, refer to the .NET class library documentation. - For information on user-defined enumerations in ABL, see the ENUM statement.