Open all | Close all

Read SAP texts



The following code shows the syntax of the FM 'READ_TEXT'. You pass it the Text Identification Details
and it will retrieve the texts into the internal table (IT_TEXTS).

*Internal table to store standard texts
DATA: IT_TEXTS like T_LINE occurs o with header line.

CALL FUNCTION 'READ_TEXT'
     EXPORTING
*         CLIENT                  = SY-MANDT
          id                      =       "Text ID
          language                =       "Laguage
          name                    =       "Text name
          object                  =       "text object
*         ARCHIVE_HANDLE          = 0
*    IMPORTING
*         HEADER                  =
     tables
          lines                   = IT_TEXTS   "Internal table
*    EXCEPTIONS
*         ID                      = 1
*         LANGUAGE                = 2
*         NAME                    = 3
*         NOT_FOUND               = 4
*         OBJECT                  = 5
*         REFERENCE_CHECK         = 6
*         WRONG_ACCESS_TO_ARCHIVE = 7
*         OTHERS                  = 8
          .
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
*         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.


SAP ABAP development help
More SAP ABAP development help and information


ABAP code and information
More SAP ABAP development tips and tricks

 
 

Number of SAP Development Users currently online hit counters