READ_TEXT_INLINE provides a text for the application program in the specified work areas. You must specify these work areas with all SAPscript function modules that process the text.
The function module reads a text from the text file or the text memory. You must fully specify the text using OBJECT, NAME, ID, and LANGUAGE. An internal work area can hold only one text; therefore, generic specifications are not allowed with these options.
In addition, the system transfers as many lines from the LINES table to the INLINES table as specified in the parameter INLINE_COUNT. You can use this lines table to display the first text lines on any screen for the user to modify them. At the event PAI, you must then call the function module EDIT_TEXT_INLINE.
Function call:
CALL FUNCTION 'READ_TEXT_INLINE'
EXPORTING OBJECT = ?...
NAME = ?...
ID = ?...
LANGUAGE = ?...
INLINE_COUNT = ?...
IMPORTING HEADER =
TABLES LINES = ?...
INLINES = ?...
EXCEPTIONS ID =
LANGUAGE =
NAME =
NOT_FOUND =
OBJECT =
REFERENCE_CHECK =
Export parameters:
OBJECT |
Enter the name of the text object to which the text is allocated. Table TTXOB contains the valid text objects. Reference field: THEAD-TDOBJECT |
NAME |
Enter the name of the text module. The name may be up to 70 characters long. Its internal structure depends on the text object used. Reference field: THEAD-TDNAME |
ID |
Enter the text ID of the text module. Table TTXID contains the valid text IDs, depending on the text object. Reference field: THEAD-TDID |
LANGUAGE |
Enter the language key of the text module. The system accepts only languages that are defined in table T002. Reference field: THEAD-TDSPRAS |
INLINE_COUNT |
Specify the number of lines you want the system to transfer to table INLINES from the beginning of the text lines table LINES. |
Import parameters:
HEADER |
If the system finds the text, it returns the table header in this parameter. Structure: THEAD |
Table parameters:
LINES |
The table contains all text lines that belong to the text read. Structure: TLINE |
INLINES |
The table contains as many lines of table LINES as specified in the parameter INLINE_COUNT. Structure: TLINE |
Exceptions
:ID |
The text ID specified in the parameter ID does not exist in table TTXID. It must be defined there together with the object of the text module. |
LANGUAGE |
The parameter LANGUAGE contains a language key that does not exist in table T002. |
NAME |
The parameter NAME contains the name of a text module that does not correspond to the SAPscript conventions. Possible errors:
|
OBJECT |
The parameter OBJECT contains the name of a text object that does not exist in table TTXOB. |
NOT_FOUND |
The system did not find the specified text module. |
REFERENCE_CHECK |
The text module to be read has no text lines of its own but refers to the lines of another text module. This reference chain can include several levels. For the current text, the chain is interrupted, that is, one of the text modules referred to in the chain no longer exists. |