Application Development 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: 

Strings longer than the editor window

Former Member
0 Kudos
150

HI !

I want to define a char variable and fill it with a string

like

DATA: myString type CHAR255.

myString = 'ashgdfhgashdf dhfghasdf sd hdsf'.

but the editor automatically makes a linefeat and shows an error if i want to aktivate it.

editor makes something like that:

myString = 'ashgdfhgashdf dhfghasdf

sd hdsf'.

Can i insert a sign or something else to write strings longer than about 80 chars??

mfg Markus

1 ACCEPTED SOLUTION

VXLozano
Active Contributor
0 Kudos
117

If you are able to write the entire string in a single line, you can do something like:

mystring =

'ldkfjldskjfsldfkjdslfkjdslfkjdsfdsf'.

If not, I think you will need to use concatenate.

mystring = 'part1 of text'.

CONCATENATE mystring 'part2 of text'

INTO mystring.

CONCATENATE mystring 'part3 of text'

INTO mystring.

Many times as needed.

Wish it helps.

4 REPLIES 4

Former Member
0 Kudos
117

Hi Markus,

Up to 4.6 the editor is limited to 72 char. But you can use the CONCATENATE statement to accomplish this...

Regards,

John.

VXLozano
Active Contributor
0 Kudos
118

If you are able to write the entire string in a single line, you can do something like:

mystring =

'ldkfjldskjfsldfkjdslfkjdslfkjdsfdsf'.

If not, I think you will need to use concatenate.

mystring = 'part1 of text'.

CONCATENATE mystring 'part2 of text'

INTO mystring.

CONCATENATE mystring 'part3 of text'

INTO mystring.

Many times as needed.

Wish it helps.

ssimsekler
Active Contributor
0 Kudos
117

Hi

I guess you can use: (That is use ampersand character to concatenate literals)

myString = 'abcdefghijklmnopqr' &
'stuxwyz' .

*--Serdar

Former Member
0 Kudos
117

Hi Markus,

You might know this already but still try changing the user specific settings of the Editor. Just uncheck the default length 72.

HTH,

Zubair