TXTCCSID is the CCSID of the text returned.
If a conversion occurs and is successful, this value is always equal to the CCSID-to-convert-to value. If a conversion occurs and is not successful, this is the CCSID of the message file unless the CCSID of the message file is 65534. If the CCSID of the message file is 65534, the CCSID of the message description is returned.
For example, message file MYMSGF has a CCSID of 65534. Your program needs to know the CCSID of message description TST0004. Specify the RTVMSG command as follows:
RTVMSG MSGF(MYMSGF) MSGID(TST0004) CCSID(*HEX) TXTCCSID(&TXTCCSID);
The CCSID of the message description is returned in the variable &TXTCCSID because you specified *HEX for the CCSID-to-convert-to parameter. *HEX means no conversion is to occur. If no conversion occurs and the message file CCSID is 65534, the message description CCSID is returned.
You can also obtain the message description CCSID from the Work with Message Descriptions (WRKMSGD) display.