Rational Programming Patterns

Automatic and explicit error messages

Error messages are automatically generated from the standard controls performed when a Screen calls a Segment or a Data Element. However, you can override these automatic messages, or declare explicit messages which correspond to errors described in specific code.

Automatic error messages

Automatic error messages correspond to the controls entered on the Screen -CE Lines and to each file access.

Error messages are divided into two parts:
  • A message specifying the error type and therefore related to the control or file access type. These standard error messages are stored in one of the system files (however, they can be modified on-site by the database administrator).
  • The Segment or Data Element name (except for Segments used in display).
Four standard error messages for validations on Data Elements are generated:
  • INVALID ABSENCE FOR THE FIELD
  • INVALID PRESENCE FOR THE FIELD
  • NON-NUMERICAL/NON-ALPHABETICAL CLASS FIELD
  • INVALID VALUE FOR THE FIELD
The following standard file access error messages are automatically generated for Segments:
  • Segments used for input:
    • INVALID CREATION RECORD
    • INVALID MODIFY/DELETE RECORD
    Both messages include the Segment name.
  • Segments used for display:
    • END OF LIST
These automatically generated error messages can be customized to your needs in the -GE Lines section of the -G Lines tab.

Explicit error messages

Only the controls entered on the Screen Call of Elements (-CE Lines tab) and file accesses trigger the automatic generation of error messages.

For other error types detected through other controls, error messages must be explicitly entered. To do so, open the -GE Lines section of the -G Lines tab associated with the Screen or Dialog, depending on the type of error.


Terms of use | Feedback

This information center is powered by Eclipse technology. (http://www.eclipse.org)