contents.gifprev1.gifnext1.gif

MESSAGE_TEXT

Returns a message text.

Description:

MESSAGE_TEXT processes a message and returns a message string with out displaying th emessage. MESSAGE_TEXT provides user control of error messages. The first parameter provides an index to look up a specific error, it must be either a keyword or integer. The optional second parameter selects which elements of the error message to return. The flag values are listed in the following table:

Bit Constant Element

0 TPU$K_MESSAGE_TEXT Text of message

1 TPU$K_MESSAGE_ID Message identifier

2 TPU$K_MESSAGE_SEVERITY Severity level indicator

3 TPU$K_MESSAGE_FACILITY Facility name

The optional third parameter can be used with the messages that take arguments to complete their message. The parameter is processed by the FAO built-in.

Syntax:

string := MESSAGE_TEXT ( message )

string := MESSAGE_TEXT ( message, integer )

string := MESSAGE_TEXT ( message, integer, FAO-parameter(s) )

Valid message values are either: Integer or keyword.

Example:

The following example inserts at the current position the following string: "%TPU-W-BEGOFBUF, attempting to move past the beginning of buffer user$buff".

COPY_TEXT (MESSAGE_TEXT (TPU$_BEGOFBUF, 15, 'user$buff'));

Errors:

TPU$_FLAGTRUNC Message flag exceeds 4 bits.

TPU$_INVFAOPARAM Argument must be an integer or string.

TPU$_SYSERROR Error getting message from table.

Related Builtins:

FAO

MESSAGE