RTVMSGD RETRIEVE MESSAGE DESCRIPTION TAAMSHC
The Retrieve Message Description command differs from the system
RTVMSG command in that the system command returns a formatted message
with substituted message variables. The TAA Tool RTVMSGD returns the
message as it exists as a message description with & values shown.
The API QMHRTVM is used to retrieve the information.
RTVMSGD is designed for the case where you want to see the message as
it exists in the message file and not the way it appears in the job
log with message variables included.
Only the first and second level text parameters are supported. For
the other values of a message description (such as LOGPRB), use the
system RTVMSG command.
A typical series of commands would be:
DCL &FSTLVL *CHAR LEN(132)
DCL &SECLVL *CHAR LEN(3000)
RTVMSGD MSGID(xxxxxxx) FSTLVL(&FSTLVL) SECLVL(&SECLVL)
The message file defaults to QCPFMSG in *LIBL.
The FSTLVL variable must be declared as 132 bytes (the largest first
level text that may be entered in a message description). The SECLVL
variable must be declared as 3000 bytes.
In most cases, the text you may be interested in will be 80 bytes for
FSTLVL and some smaller value for SECLVL. You must declare
additional variables for the length desired and then move the
returned values to your specific length variables.
Command parameters *CMD
MSGID The message ID to be retrieved.
FSTLVL An optional return variable for the first level text
of the message. If used, it must be declared as
*CHAR LEN(132). In many cases you will want to move
the data to an 80 character variable as most
messages do not exceed 80 bytes.
SECLVL An optional return variable for the second level
text of the message. If used, it must be declared
as *CHAR LEN(3000).
If the message exceeds 3000 bytes, only the first
3000 are returned. In most cases you will want to
move the data to a shorter variable.
MSGF The qualified name of the message file where the
message exists. The message file name defaults to
QCPFMSG and the library defaults to *LIBL. *CURLIB
may also be used.
FMTCTLCHAR Whether to retrieve the format control characters
(&N &P &B). The default is *NO. A *YES entry
returns the control characters.
Only 3000 bytes of second level text are returned.
None, the tool is ready to use.
Objects used by the tool
Object Type Attribute Src member Src file
------ ---- --------- ---------- ----------
RTVMSGD *CMD TAAMSHC QATTCMD
TAAMSHCC *PGM CLP TAAMSHCC QATTCL
Added to TAA Productivity tools May 1, 1996