Previous Next

Progress.Lang.AppError class
Progress.Lang.AppError is the ultimate super class of all application errors. An application error is simply any collection of data you need to provide meaningful information about a condition. Representing a user-defined error as an error object allows your application to throw and catch or return the error in the ABL structured error handling model.
Note:
The following figure represents the hierarchy of ABL classes that provide Progress.Lang.AppError with all its features:
Progress.Lang.ProError is the ultimate super class of all error objects in ABL. From Progress.Lang.Object it inherits the basic features of an ABL class. It also implements the Progress.Lang.Error interface which provides the basic properties and methods for handling errors.
Progress.Lang.AppError adds the properties and methods needed for populating an AppError object with your error messages.
You can create your own hierarchy of more complex AppError types by subclassing AppError.
When the AVM encounters the RETURN ERROR statement, it implicitly throws a Progress.Lang.AppError error object and places any error string in the object’s ReturnValue property.
Constructors
The following is the default constructor. This constructor creates an AppError object with an empty message list and does not set any properties.
 
Syntax 
PUBLIC AppError ( )
The following constructor creates an AppError object and assigns the first message on the object with the values from the ErrorMessage and MessageNumber arguments. It also sets the NumMessages property to 1. This error message and message number can be accessed with the GetMessage(1) and GetMessageNum(1) methods.
 
Syntax 
PUBLIC AppError ( INPUT ErrorMessage   AS CHARACTER 
                  INPUT MessageNumber AS INTEGER )
The following constructor creates an AppError object with the ReturnValue property set with the value of the ErrorString parameter. This constructor is used when the AVM implicitly creates an AppError object for a RETURN ERROR ErrorString statement. You can also invoke this constructor directly.
 
Syntax 
PUBLIC AppError ( INPUT ReturnValue AS CHARACTER )
Super Class
Progress.Lang.ProError class
Interfaces
This class does not implement interfaces (beyond those it inherits from its base class).
Public
Properties
 
Public
Methods
 
Public
Events

This class does not contain events.
Note 
All AppError instances, both those created implicitly and user-defined application errors, created with the NEW function (classes) appear on the SESSION:FIRST-OBJECT chain, just like any other user-defined object.
See also 
Progress.Lang.SysError class

Previous Next
© 2013 Progress Software Corporation and/or its subsidiaries or affiliates.