Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Line break within string

Former Member
0 Likes
689

Hi all,

I want to create a string including a line break, like \n in C programming.

But I do NOT want to split lines with ULINE command, I do want the CRLF in the string.

So I tried this:

CONCATENATE 'LINE1' 'LINE2' INTO v_line SEPARATED BY cl_abap_char_utilities=>cr_lf.

But unfortunately that prints this output to the report's list:

LINE1##LINE2

Any ideas?

Kind regards, Matthias

PS: it's a Unicode system

5 REPLIES 5
Read only

Former Member
0 Likes
653

Hi Matthias,

Try this code.

CONCATENATE 'LINE1' 'LINE2' INTO v_line SEPARATED BY ' ' RESPECTING BLANKS.

Hope this is helpful to you. If you need further information, revert back.

Reward all the helpful answers.

Regards

Nagaraj T

Read only

0 Likes
653

Hi Nagaraj,

this solution does not work either. It gives me the following output

 LINE1 LINE2

Both "lines" are separated only by a blank, not by a newline.

Kind regards, Matthias

Read only

0 Likes
653

Hi mathias !

Did you get the answer to that question? I'm having the same problem.

Thanks;

C.K.

Read only

Former Member
0 Likes
653

hi this is not problem...

it will seems like that but at the time of downloading from the application server it will give the good result ..like

line1 line2

Read only

Former Member
0 Likes
653

hiii

i dont think its possible by only using concatenate statement..you can use shift right statement after using concatenate statement.i think it will give you your desired output.

regards

twinkal