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

fm save_text line insertion

Former Member
7,521

i am using this fm SAVE_TEXT to write the texts in tcode va03,

how do I write the texts "below" to the other texts (as if from a "send" and wrap)

for example:

text already present: 'AAAA'

text to put in the queue: 'BBBB'

I want the text to be inserted like this:

'AAAA'

'BBBB'

and not like this: 'AAAA BBBB'

(to read the old text I use the read_text fm)

i am using this fm SAVE_TEXT to write the texts in tcode va03,

how do I write the texts "below" to the other texts (as if from a "send" and wrap)

for example:

text already present: 'AAAA'

text to put in the queue: 'BBBB'

I want the text to be inserted like this:

'AAAA'

'BBBB'

and not like this: 'AAAA BBBB'

(to read the old text I use the read_text fm)

13 REPLIES 13
Read only

FredericGirod
Active Contributor
0 Likes
6,351

LINES

TD /

TDLINE AAAA

TD /

TDLINE BBBB

does not work ?

Read only

Dominik_Tylczynski
SAP Champion
SAP Champion
6,351

If I understood correctly your question, it's about filling SAVE_TEXT LINES parameter to either save the texts as one line or as separate lines.

Here are the screen shots with LINES content SAVE_TEXT test environment.

To save texts in seperate lines i.e. as:

AAAA

BBBB

To save texts in one linee i.e. as:

AAAA BBBB

Refer also to the documentation of TDFORMAT field in LINES import parameter of SAVE_TEXT.

Dominik Tylczynski

Read only

6,351

The list of predefined paragraph formats (* , = and so on) are explained here: SAP Library: Structure TLINE of the Lines Table

Read only

0 Likes
6,351

to write the text below the previous one, do I have to put the '=' sign in the tdformat field?

Read only

0 Likes
6,351

Yes, that’s what you need to put according to the field documentation.

Read only

6,351

nick reyan The documentation says:

  • = long line

    This line is not subject to the line formatting in the SAPscript editor. The text contained in this line is also appended directly to the character of the preceding text line which was output last. If this is not required, there must be at least one blank at the beginning of the extended line.

Read only

Former Member
0 Likes
6,351

Hello Nick,

At first, you have to use READ_TEXT for read the actual text in VA03.

The internal table (LINES type TLINE) only contains 'AAAA'

Then you fill the WA of your itab with the new text 'BBBB'.

You insert your WA into Itab : insert wa into itab.

Then you have :

Line 1 : 'AAAA'

Line 2 : 'BBBB'

And now you can save the text with SAVE_TEXT

Cedric

Read only

0 Likes
6,351

I tried, it does not wrap

Read only

Former Member
0 Likes
6,351

puoi fare un esempio di una riga di codice?

can you make an example of a line of code?

where should I put "td /"? if in the previous string I have the value 'AAAA' I add '/' and then 'BBBB' should you write them all over again?

Read only

Former Member
0 Likes
6,351

sorry try can you try :

APPEND wa to itab

Read only

michael_piesche
Active Contributor
0 Likes
6,351

These are teh possible formatting parameters for TDFORMAT. You are probably wanting to do * or /.

  • * Default Paragraph
  • B Paragraph, justified
  • C Centered
  • L Paragraph, left-aligned
  • Continuous Text
  • = Extended Line
  • ( Raw Line
  • / Line Feed
  • /= Line Feed and Extended Line
  • /( Line Feed and Raw Line
  • /: Command Line
  • /* Comment Line

You could also view your text and change the editor from "WYSIWYG" (eg Word) to the SAPscript editor and see how it is stored there (see below screenshot for an example).

Read only

6,351

SAP Library: Structure TLINE of the Lines Table says:

  • * default paragraph

    The format definitions which are specified for the paragraph defined in the assigned style or form as the default paragraph are used for the output formatting of the paragraph involved.

  • / new line

    The subsequent text is written to a new line during output formatting. The formatting specifications of the last paragraph format apply.

Read only

michael_piesche
Active Contributor
0 Likes
6,351

nick.reyan, please follow up on your open question.

  • comment answers or your question if there are still open issues.
  • otherwise mark an answer as accepted if it helped you solve your problem
  • or post an answer of yourself and accept it if you found another useful solution yourself
  • or redirect your question to another question that is related and was useful to solve your problem
  • in the end, close your question