Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Email Attachment format issues

Hi All,

I am using CL_BCS_DOCUMENT to send emails, as I need to send multiple attachments. Here is the code I am using.

vo_document = cl_document_bcs=>create_document(

i_type = 'RAW'

i_text = it_message

i_subject = subject ).

CALL METHOD vo_document->add_attachment


i_attachment_type = 'TXT'

i_attachment_subject = 'Input file'

i_att_content_text = it_data.

The issue is that the data in the attachment is not as formatted in the internal table. I think the data in the attachment is getting concatenated until 1024 chars are reached, and then spill over to the next line.

Suppose my internal table line size is 256 chars, then 4 lines will appear in the first line of the text attachment, and so on....

I want each line in the internal table to be a separate lines in the attachment.

Thanks in advance.

Former Member
Not what you were looking for? View more on this topic or Ask a question