Start of Content Area

Text Lines  Locate the document in its SAP Library structure

The lines of a text are stored in an internal table. Each line consists of a format field and a field with the actual line contents. The contents of these fields is determined by the text format specified in the field TDTEXTTYPE of the text header. Texts may have SAPscript format as well as other formats (for example, WinWord DOC or RTF format).

A text has SAPscript format if the field TDTEXTTYPE is empty. The texts are stored in the line table exactly as they appear in the SAPscript text editor. This SAPscript format is called ITF format. It consists only of those system characters that can be displayed on the screen and does not contain any hexadecimal codes to control formatting.

The two-character format field specifies the paragraph type for the subsequent text line. The possible paragraph formats as well as the underlying formatting options are defined in the style or form. Special paragraph formats determine whether the line contents are SAPscript control statements or, for example, comment lines. These paragraph formats are valid for all text modules. The text line field contains either text or a SAPscript statement, if it is a command line.

The ITF format is no final format; that means, you need the SAPscript composer to create the output format (OTF format) using the layout definitions of the style and the form.

You can use SAPscript to maintain texts that have a format SAPscript cannot process. The field TDTEXTTYPE in the header of these texts then specifies the respective text format. The text lines of these tests are nevertheless stored in an internal table, which has the structure TLINE. The structure of the individual text lines depends on the respective format. To pass texts in a non-SAPscript format, you can use only the following SAPscript function modules:

 

READ_TEXT

INIT_TEXT

DELETE_TEXT

COPY_TEXTS

SAVE_TEXT

SELECT_TEXT

RENAME_TEXT

COMMIT_TEXT

EDIT_TEXT

PRINT_TEXT

 

Caution

You cannot mix texts in SAPscript format with texts in another format. This results in restrictions for using texts in other formats:

SAPscript does not interpret the contents of the text line table, but passes the table to the corresponding word processing program, which is designed to process the respective text format. The transfer happens automatically due to the function modules EDIT_TEXT or PRINT_TEXT, which internally call the function modules EDIT_TEXT_FORMAT_xxx or PRINT_TEXT_FORMAT_xxx (xxx = contents of field TDTEXTTYPE). These function modules provide the connection to the corresponding word processing programs.