Skip to main content

MessageHandler Variable

Allows you to customize messages shown to the user.

Declaration

export var MessageHandler: (newVal?: IMessageHandler) => IMessageHandler;

Members

Type
(newVal?: IMessageHandler) => IMessageHandler

Remarks

Use the MessageHandler property to customize error messages shown to the user, as demonstrated in the following code snippet:

DevExpress.Reporting.Viewer.Settings.MessageHandler.processError
    = function (message, showForUser, prefix) {
            DevExpress.Analytics.Internal.ShowMessage(prefix.substring(0, prefix.length - 2));
        };

The picture below shows the Document Viewer, which attempts to load the “TestReport1” report whose data is corrupted. A custom error message is displayed: