Skip to Content
Former Member
Jun 19, 2007 at 01:28 PM

concatenate strings without trim space


Hi, i am looking for a Method in ABAP that concatenate strings without trim space on any string.

I will send a PDF-Document from the archivelink as attachment in an E-Mail, but the archivelink function deliver the document in lines with 1024 character und the input function for the attachment of the E-Mail need the document in lines with 255 character.

I think, concatenate all lines und seperate them, but sometimes i lose a space.

I try some solutions:

DATA l_document(65535) TYPE c.

DATA line_doc_length TYPE i.

line_doc_length = 0.

LOOP AT archivobject INTO wa_archivobject.

l_document+line_doc_length = wa_archivobject.

line_doc_length = line_doc_length + 1024.


That solution match, but the max length of the document is 65535 character.

I try the same with a dynamic Object like 'Create Data ...', but in this case it is not allowed to use an offset.

Thanks for help

Frank Dehle