Try OpenEdge Now
skip to main content
Messaging and ESB
ABL - JMS API Reference : setErrorHandler procedure
 

setErrorHandler procedure

Sets the error-handling procedure.

Syntax

PROCEDURE setErrorHandler.
DEFINE INPUT PARAMETER messageConsumer AS HANDLE.

Applies to

Session objects

Notes

*The application must create the error-handling messageConsumer object and call setErrorHandlerprocedure after calling beginSessionprocedure . If the application does not call setErrorHandlerprocedure, a default error handler displays the error message and the properties in alert boxes.
*The application should handle asynchronously reported error conditions programmatically by creating an error-handling Message Consumer object and passing it to setErrorHandlerprocedure in the Session object. setErrorHandlerprocedure creates an error-handling Message Consumer object.
*Asynchronous conditions are always reported as a TextMessage with several possible CHARACTER message properties. The CHARACTER properties that might be included in the message header are: exception, errorCode, linkedException-1, linkedException-2 … linkedException-n (where n is a number of additional exceptions linked to the main exception).
*getPropertyNamesfunction can be used to get the list of properties in the error message header.

See also

setErrorHandlerprocedure, setNoErrorDisplayprocedure
For more information, see the Error and condition handling. For an example, see Messaging Examples.