IBM Support

Specifying More than 255-bytes of Message Text without Using Body Files

Troubleshooting


Problem

This document discusses how to specify more than 255-bytes of text text without using body files when using a PDF mapping program with Infoprint Server. This is particularly useful when Infoprint Server will be sending PDF files to e-mail clients

Resolving The Problem

This document discusses how to specify more than 255-bytes of text text without using body files when using a PDF mapping program with Infoprint Server. This is particularly useful when Infoprint Server will be sending PDF files to e-mail clients that require a Messaging Application Programming Interface (MAPI) interface, such as Microsoft Outlook.

This document was last updated on 3 June 2013.





The e-mail client application that receives the e-mail may not support the body text feature. For example, the Lotus Notes e-mail client supports the body text feature, but the Microsoft Outlook Express e-mail client does not. Outlook Express displays any body text as an attachment, not as included text.

E-mail clients that require a MAPI interface, such as Microsoft Outlook, do not display the text as part of the e-mail's body because the MAPI interface is not available on i5/OS. Instead, the text files are displayed as attachments.

One way around this issue would be to change to use message text instead of using body text.


Using Message Text instead of Body Text

The message text field is limited to 255 bytes when using a PDF mapping object. However, an enhancement was made to V5R2M0 OS/400, by way of PTFs, to allow customers who develop their own PDF mapping programs to have more than 255 bytes of message text inserted into the body of an e-mail.

This enhancement requires setting up Infoprint Server to send e-mails using an SMTP server. The new feature is not available for:
- Customers using *SNDDST as a PDF Mail Server.
- Customers using a PDF mapping object.

Note: If you are using any of the following e-mail clients you may not need to use this new support: Microsoft Outlook Express, Eudora, Thunderbird, Lotus Notes and Yahoo!. These e-mail clients display files placed into the body of an e-mail as expected.

The Mapping Program Output structure used by map programs has been updated to include a field called Offset to message text data at decimal offset 280. The size of the Mapping Program Output structure has not changed. Note that the reserved field following Offset to message text data has been changed from CHAR(7) to CHAR(3). Shown below is an update of the structure as documented in Infoprint Series for iSeries User's Guide (G544-5775-03).

Decimal OffsetHex OffsetTypeDescription
00CHAR(1)Disposition of PDF e-mail
11CHAR(1)More processing
22CHAR(2)Reserved (set each byte to X'00')
44BINARY(4)Length of message text
88BINARY(4)Length of mail address
12CCHAR(255)Message text
267 10BCHAR(1)Reserved (set to X'00')
268 10CBINARY(4)Offset to extension area
272 110BINARY(4)CCSID of message text and subject
276 114CHAR(1)Disposition of PDF Stream file
277 115CHAR(1)Disposition of PDF Spooled file
278 116CHAR(1)Disposition of PDF Error
279117CHAR(1)Disposition of AFPDS Spooled file
280118BINARY(4)Offset to message text data
28411CCHAR(3)Reserved (set each byte to X'00')
28711FCHAR(*)E-mail address

Offset to message text data.

Offset from the beginning of this structure. The value must be a 4-byte multiple Use this field if you specify more than 255 bytes of message text data. If you are using the Message text data field, specify a value of zero for Offset to message text data.

The updated headers files used by map programs are provided with the V5R2M0 PTFs for APAR SE22574.

Programming tips

1New lines in the message text may be produced by writing the line feed and carriage control hexadecimal values, X'0D25', into the message text data.
2If your current map program does not need to use this new function, there is no need to make any changes to the code or recompile the program.
3Offset to message text data can be used irrespective of the value specified for Length of message text. In other words, Offset to message text data may be used for any length of message text, even when less than 255.
4Offset to message text data is an optional field. If not being used, set its value to X'0000'.

Notes:
oMessage PQT4140 "Incorrect data was returned by mapping program (&1/&2)" reason code 43 or RC43 indicates that the PDF mapping program specified a value greater than 255 for Length of message text but specified a value of zero for Offset to message text. An offset greater than zero must be specified when a value greater than 255 is specified for Length of message text.
oThe diagnostic spooled file that can be produced when using a map program has been updated to display message text containing more than 255 characters. This data will be indicated by the string 'MSG TEXT'. The actual message text will be output on the lines following this string.
oFor more information on the diagnostic spooled file, please refer to the Trouble_Shoot_Map_Programs.htm file that is provided with this enhancement. The document can be found on your system at /qibm/proddata/os400/PrintServicesFacility/, but has also been attached to this document:

Trouble_Shoot_Map_Programs.htm


References

For additional information and restrictions for this option, refer to Appendix B, PDF Mapping Program in the Infoprint Server for iSeries User's Guide, Version 5, Release 2.0, G544-5775-01 in the Extension Area Format section.

Infoprint Server for iSeries User's Guide (G544-5775-05):
7.1http://pic.dhe.ibm.com/infocenter/iseries/v6r1m0/topic/rzair/g5445775.pdf
6.1http://pic.dhe.ibm.com/infocenter/iseries/v6r1m0/topic/rzair/g5445775.pdf
5.4http://publib.boulder.ibm.com/infocenter/iseries/v5r4/topic/books/g5445775.pdf

Infoprint Server for iSeries Planning Guide (G544-5774-03):
7.1http://pic.dhe.ibm.com/infocenter/iseries/v6r1m0/topic/books_web/g5445774.pdf
6.1http://pic.dhe.ibm.com/infocenter/iseries/v6r1m0/topic/books_web/g5445774.pdf
5.4http://publib.boulder.ibm.com/infocenter/iseries/v5r4/topic/books/g5445774.pdf


[{"Type":"MASTER","Line of Business":{"code":"LOB57","label":"Power"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SWG60","label":"IBM i"},"Platform":[{"code":"PF012","label":"IBM i"}],"Version":"6.1.0"}]

Historical Number

534088869

Document Information

Modified date:
11 November 2019

UID

nas8N1012777