mig28mx
9th September 2010, 18:16
Hello all,
I have a text with the form:
line1
line2
line3

this mean all lines are followed by a line feed. By example, table tttxt010

If I call the specific text on a report, the text will split into several lines as many as line feeds that contains.

I want to print that text file in the form:
line1 line2 line3

Anybody knows how to skip that line feed? or faced a similar problem?

Thank you in advance.

BaanInOhio
9th September 2010, 19:45
You can use the text.to.buf call to put each line of text into a separate string within an array. First use text.present.in.language to determine how many lines are present, then allocate to a dynamic string array with the number of lines for a width long enough to store each line. Once you have the array filled, you can concatenate each array string into a single string. Before adding the next string in the array to the single string (for form or report), you should check the string length after addition of the next string to ensure that you don't exceed the length of the string.

mig28mx
14th September 2010, 19:42
Thanks for your reply BaanInOhio,
Your idea cleared my mind.

Regards.