cancel
Showing results for 
Search instead for 
Did you mean: 

How to manage long formatted texts

Former Member
0 Kudos

I am working on a WDA application that has descriptive texts in different iViews. These texts are all formatted texts. The easiest way for now is to hard-coded all texts. However, these texts may be subject to change in the future. So, I am thinking to build a WDA application for end users to edit these texts through FormattedTextEdit, and the texts are stored in a Z-table. My question is, is there any better solution for this case?

Accepted Solutions (1)

Accepted Solutions (1)

amy_king
Active Contributor
0 Kudos

Hi Dayong,

Rather than store your texts in a z table, you can store them in standard text objects. You can call function module SAVE_TEXT to save your texts and function module READ_TEXT to read the stored texts.

When saving your texts, function module SWA_STRING_SPLIT can be called to split your formatted text string into a table of 132-character strings suitable to pass to SAVE_TEXT. When reading your stored texts with READ_TEXT, you can detect the TLINE-TDFORMAT newline character * and replace it with CL_ABAP_CHAR_UTILITIES=>CR_LF to preserve newlines in the text.

Cheers,

Amy

Former Member
0 Kudos

Thank you!

Answers (0)