You can determine the size of a message by using the following formula. (The ADDMSGD command parameters are given in parentheses.)
The smallest possible entry in a message file is 59 bytes and the largest
possible entry is 5764 bytes. The following table describes the largest
possible entry:
Message index | 42 bytes |
Message text | 148 bytes |
Message help text | 3016 bytes |
99 formats | 311 bytes |
Type and length | 48 bytes |
20 special values | 1282 bytes |
20 values | 640 bytes |
Default reply value | 32 bytes |
Default program and dump list | 233 bytes |
Alert option | 12 bytes |
In the following example, the CRTMSGF command creates the message file USRMSG:
CRTMSGF MSGF(QGPL/USRMSG) + TEXT('Message file for user-created messages')
If you are creating a message file to be used with the DSPLY operation code in RPG for OS/400, the message file must be named QUSERMSG.
(C) Copyright IBM Corporation 1992, 2005. All Rights Reserved.