Informational Messages

Informational Messages inform the user that some condition has occurred in the iTool application. The condition may be an error, but it can also be any other occurrence of which the user should be informed. Informational messages are presented as modal dialogs, generally with a single OK button that dismisses the dialog.

Figure 12-3: An informational message dialog.

ErrorMessage.gif

The IDLitIMessaging class provides the ErrorMessage method to display informational messages of all sorts.

ErrorMessage

The IDLitIMessaging::ErrorMessage method displays an informational text message to the user. In the standard iTool interface created using the IDL widget toolkit, informational messages appear as modal dialogs as shown in Figure 12-3.

Informational messages can use any of three severity codes, indicating to the user whether the message is merely informational, is a warning, or reports a serious error. While the severity setting does not alter the behavior of the dialog, which can only be dismissed by the user, it can alter the appearance of the dialog. For example, the dialog shown in Figure 12-3 has a severity setting of 0, or "Informational".

The following code displays an informational message:

self->ErrorMessage, ['The following variables were exported:', $ 
   'Plot_Y'], SEVERITY = 0, TITLE = 'Export Complete' 

The value of the TITLE keyword is displayed in the title bar of the dialog box.

In addition to the ErrorMessage method, the IDLitIMessaging class provides the SignalError method, which reports an error condition to the iTool system but which does not display the message to the user. See "IDLitIMessaging" (IDL Reference Guide) for details.