Documentation View

We are hiring and constantly growing! Have a look through our vacancies to find the right role for you!

ABAPSET_LANGUAGE - SET LANGUAGE

ABAPSET_LANGUAGE - SET LANGUAGE

RFUMSV00 - Advance Return for Tax on Sales/Purchases   General Material Data  
This documentation is copyright by SAP AG.
SAP E-Book

SET LANGUAGE

Short Reference



SET LANGUAGE lang.

Effect

This statement loads the list headers and text symbols for the text pool of the language specified in lang. lang must be a character-like data object that contains a language key with the length 1. The possible language keys are contained in the SPRAS column of the database table T002. The loaded text elements apply only to the current program and not to the programs called within it. If lang contains a space, the behavior is undefined.

If there is no text pool for the specified language, the text pool of the secondary language of AS ABAP is loaded. If a secondary language is not set, no new text pool is loaded and sy-subrc is set to 4. In this case, the program continues to use the text elements of the previous text pool.

If list headers and text symbols are missing in a text pool loaded using SET LANGUAGE but existed in the previously loaded text pool, these are initialized.

System Fields

sy-subrc Meaning
0 The text pool of the specified language or secondary language was loaded.
4 Neither the text pool of the specified language nor the secondary language could be loaded.

Notes

  • When calling a program, the system loads the text pool in the logon language by default. If this text pool does not exist, the system loads the text pool in the secondary language. If this text pool also does not exist, all text elements remain initialized.
  • The SET LANGUAGE statement does not load the selection texts of the language specified. If this is necessary, the statement READ TEXTPOOL can be used. The selection texts read in can then be displayed on the selection screen using the function modules SELECTION_TEXTS_MODIFY and SELECTION_TEXTS_MODIFY_DTEL.
  • The statement SET LANGUAGE must not be confused with the statement SET LOCALE LANGUAGE for setting the text environment. In particular, there is no corresponding GET LANGUAGE statement.

Example

Display of the text symbol text-010 in different languages. Output is produced for all languages for which the text pool exists in the specified language or in the secondary language.






rdisp/max_wprun_time - Maximum work process run time   RFUMSV00 - Advance Return for Tax on Sales/Purchases  
This documentation is copyright by SAP AG.

Length: 3883 Date: 20230207 Time: 093248     sap01-206 ( 81 ms )