cancel
Showing results for 
Search instead for 
Did you mean: 

EMail Attachment with CRLF

0 Kudos

Hi All,

While generating the email attachment(csv file ) through PI using Java Mapping/UDF, CRLF is replaced by LF(seen as box character in notepad) being on Unix platform.

Following things have been tried -

1. running unix command through Java Map.

2. Setting different char encodings

3. Setting Server Parameter to UTF - 8

4. We also have tried using ASMA and then setting the end seperator in channel. In this case it works but then we are unable to have email body content which is a mandatory requirement.

None of them worked .

Any pointers will be helpful.

Thanks ,

Piyusha

Accepted Solutions (1)

Accepted Solutions (1)

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

there is a standard SAP adapter module - ConvertCRLFfromToLF

which can be used to do the changes in both directions but I don't know if it works on attachments - maybe you can give it a try ? if not you can always have a look at it's code and implements yourself

http://help.sap.com/saphelp_nwpi711/helpdata/en/96/f04142099eb76be10000000a155106/content.htm

Regards,

Michal Krawczyk

0 Kudos

Hi Michal,

I have tried using the module but it do not seem to be working with Attachment.

Following config was done - Not sure if missed anything -

Processing seq -

1SAP XI Sample/ConvertCRLFfromToLFLocal Enterprise Bean1
2sap.com/com.sap.aii.adapter.mail.app/XIMailAdapterBeanLocal Enterprise Beanmail

Module config

1modeLFtoCRLF

Meanwhile , I'll try to extract the code from module.

Thanks,

Piyusha

Former Member
0 Kudos

Hi Piyusha,

Use =0D=0A for CRLF and define the Content transfer encoding as Quoted-printable in your MIME message.

String CRLF = "=0D=0A";

Content-Transfer-Encoding: quoted-printable

http://www.w3.org/Protocols/rfc1341/5_Content-Transfer-Encoding.html

Cheers,

Anish

0 Kudos

It worked. Thanks.

Answers (0)