Skip to Content
0
Former Member
Sep 18, 2007 at 04:26 PM

How to display long text in a paragraph format using class CL_GUI_TEXTEDIT?

255 Views

I need to display a long paragraph in the text editor. I realize I have to declare a very long table line for my text table. For example, I wrote a subroutine set_paragraph_text.

FORM set_paragraph_text USING p_paragraph.

DATA: l_line(1000) TYPE c,

lt_paragraph LIKE TABLE OF l_line.

APPEND p_paragraph TO lt_paragraph.

  • Display the paragraph in the text editor.

CALL METHOD g_textedit->set_text_as_r3table

EXPORTING

table = lt_paragraph.

ENDFORM. " set_paragraph_text

This approach works well in release 6.4. Will it also work for earlier versions with more stringent char length limit? If not, can anybody suggest a better solution for the problem? The bottom line is that the paragraph needs to be displayed in its natural format, not one sentence per line. Another restriction is that the paragraph text is pre-fixed so it is hard coded into the program as a string literal.

Thanks in advance for any help.