Try OpenEdge Now
skip to main content
Online Help
Introducing the ABL Editor : Tasks : Writing ABL code : Writing object-oriented code : Adding constructors
 
Adding constructors
When you create a new class, you can add a default constructor by selecting the Generate default constructor toggle in the New ABL Class wizard.
You can add constructors to an existing class as follows:
1. Choose Source > Add Constructor to launch the Add Constructor wizard.
2. Select the appropriate access modifier (Public, Protected, or Private).
3. Choose whether to include a CATCH block and/or a FINALLY block for structured error handling.
4. Select the insertion position for the constructor and click Generate. The constructor appears at the specified position in your class file.
Note: You can also add a static constructor to an existing class by choosing Source > Add Static Constructor.