ABAP Keyword Documentation →  ABAP − Reference →  program editing →  Dynamic Program Editing →  text element → 

READ TEXTPOOL  Syntax Diagram

Short Reference

Syntax

READ TEXTPOOL prog INTO itab LANGUAGE lang.

Effect

This statement reads the text elements of the text pool of the language specified in lang and the program specified in prog from the repository and places them into the internal table itab. The previous content of itab is deleted. If the text elements cannot be read, then the content of itab remains unchanged.

prog expects a flat character-like data object, which contains the name of the program of the text elements to be read; the name is not case-sensitive. The internal table itab can be in any table category and its row type must correspond to the TEXTPOOL structure in ABAP Dictionary.

lang expects a character-like flat data object. This must contain a language key with a maximum length of one character, and this value must be contained in the column SPRAS of the database table T002. If lang contains a space, the behavior is undefined.

After a successful read, itab contains, in the ENTRY column, the texts of the text symbols, the selection texts, the list headers, and the title from the program attributes. Every text element that exists for the specified language occupies one row of the internal table and is identified uniquely by the columns ID and KEY. The column LENGTH contains the length of the text element. The table below shows the possible values of the columns ID and KEY and their meaning:

ID KEY ENTRY
H 001 through 004 List header Column headers
I ID of a text symbol Text of the text symbol
R - Program title
S Name of a parameter or selection criterion Selection text
T - List header Title bar

System Fields

sy-subrc Meaning
0 At least one text element was read.
4 The program specified in prog or the language specified in lang does not exist or there is no text pool in the specified language.

Notes

Example

See INSERT TEXTPOOL




Continue
READ TEXTPOOL - Internal addition