SAP Function RPY_DOCU_READ - Read documentation of development objkects from the ABAP/4 DW

Parameter Reference Type Length Default Optional Text
DOCUTYPE RGLIF-DOCUTYPE C 1 'U' X 'U' -> Doc. in free format, 'T' -> SAPscript format
LANGUAGE SYST-LANGU C 1 SY-LANGU X Language in which documentation is to be read
OBJECTNAME DOKIL-OBJECT C 60 Name of documented object (table, ...)
OBJECTTYPE DOKIL-ID C 2 Type of object (DE, TB, DM, ET, ...)

Parameter Reference Length Optional Text
DOCU_TABLE_TECH TLINE 134 X Doc. table in SAPScript format
DOCU_TABLE_USER RPY_OBJTAB 73 X Doc. table in free format

Exception Text
CANCELLED Dialog canceled
NOT_FOUND Documentation not found
PERMISSION_ERROR User does not have display authorization

Functionality
This function module reads the documentation of ABAP/4 DevelopmentWorkbench objects into the tables intended for the purpose.
The following object types are so far supported:
'DE' Data element documentation
'TB' Table documentation
'DM' Data model documentation
'ET' Entity documentation
'DO' Domain documentation
'CL' Area documentation
'NA' Message documentation
The documentation is stored in Table RPY_DOCU_USER or RPY_DOCU_TECH,depending on the value of the DOCUTYPE parameter ('U' or 'T').
If the documentation is read with DOCUTYPE 'U', it is stored in thetable RPY_DOCU_USER in the following form:
KEY_ID ID of line type for complex objects
(1 character)
OBJLINE Text line/data description
(72 characters)
If the value of KEY_ID is other than blank, the associated line is adescription of the following documentation lines in the following form:
LENGTH Number of documentation lines for object
DOKU_ID 4-character ID of documentation
OBJECTNAM1 Name of object to which documentation is assigned
OBJECTNAM2 Entity ID (only for entities)
VARIANT Variant (only for entities)
SPECID Spezialization type (only for entities)
ROLNR Dependency roll (only for entities)
LANGUAGE Language in which documentation is stored
If the documentation is read with DOCUTYPE 'T', it is stored in thetable RPY_DOCU_TECH SAPscript format in the following form:
TDFORMAT Format column (2 characters)
TDLINE Text line (132 characters)
Each object documentation begins with a control line that is also inSAPScript format. TDFORMAT contains 'AS' and TDLINE has the followingstructure:
KEY '§'
LENGTH Number of documentation lines for object
DOKU_ID 4-character ID of documentation
OBJECTNAM1 Name of object to which documentation is assigned
OBJECTNAM2 Entity ID (only for entities)
VARIANT Variant (only for entities)
SPECID Spezialization type (only for entities)
ROLNR Dependency roll (only for entities)
LANGUAGE Language in which documentation is stored
The following documentation lines are pure SAPScript texts with theappropriate format IDs in the field TDFORMAT.

Example
CALL FUNCTION 'RPY_DOCU_READ'
EXPORTING
LANGUAGE = SY-LANGU
OBJECTNAME = 'TESTELEM'
OBJECTTYPE = 'DE'
DOCUTYPE = 'T'
TABLES
DOCU_TABLE_TECH = DOCUTAB
EXCEPTIONS
CANCELLED = 01
NOT_FOUND = 02
PERMISSION_ERROR = 03.

Further information
SAPscript documentation.