Ansicht
Dokumentation

ABAPINSERT_TEXTPOOL - INSERT TEXTPOOL

ABAPINSERT_TEXTPOOL - INSERT TEXTPOOL

TXBHW - Original Tax Base Amount in Local Currency   PERFORM Short Reference  
This documentation is copyright by SAP AG.
SAP E-Book

INSERT TEXTPOOL

Short Reference



INSERT TEXTPOOL prog FROM itab LANGUAGE lang.

Effect

This statement places the content of table itab into the repository as a text pool of the language specified in lang for the ABAP program specified in prog. If a text pool for the specified language already exists, all its text elements are overwritten. Otherwise, a new text pool is created for this language. By default, the text pool is saved in an active state.

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.

lang expects a character-like flat data object that contains 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 an invalid language is specified in lang, no text pool is created or overwritten. If lang contains a space, the behavior is undefined.

The internal table itab can be in any table category and its line type must correspond to the DDIC structure TEXTPOOL. If a nonexistent program is specified in prog, no text pool is created or overwritten.

In the internal table itab, the column ENTRY can contain the texts of the text symbols, the selection texts, the list headers, and the title for the program attributes. Their length can be specified in the column LENGTH. The individual text elements are identified using the entries in the columns ID and KEY, whose valid values are shown in the table for READ TEXTPOOL.

If the columns ID or KEY of the internal table contain invalid values or if duplicate entries exist, an inconsistent text pool is created. If the internal table is empty, all text elements of an existing text pool are deleted or a text pool without text elements is created. If the length specified in LENGTH is shorter than the text length in ENTRY, it is automatically set to the text length in the text pool.

Return Codes

The statement INSERT TEXTPOOL always sets sy-subrc to the value 0.

Notes

  • The specification of the text length in LENGTH defines the maximum length of the text element that is available in the ABAP Workbench when translating the text pool into other languages and should be set sufficiently large.
  • In the case of selection texts, there must be eight blanks before the actual text in ENTRY. If a selection text from the dictionary is to be used, the first character of ENTRY must be a "D".
  • The INSERT TEXTPOOL statement should be used with caution, because it completely overwrites existing text pools.

Example

Attempt at a translation tool for text elements. The text pools of a source and a target language are imported into internal tables and, for each text element of the source language, a selection screen is displayed as a translation template. After the translation has been completed, the text pool of the target language is overwritten with the correspondingly changed internal table.






RFUMSV00 - Advance Return for Tax on Sales/Purchases   Fill RESBD Structure from EBP Component Structure  
This documentation is copyright by SAP AG.

Length: 4557 Date: 20240329 Time: 162557     sap01-206 ( 82 ms )