2009 Feb 17 7:23 AM
Hi
Anyone give me code or link or example for how to use function module READ_TEXT
and what are the parameters which we have to pass in module.
Regards.
Mohsin
go to any text in po or sales or mm03.see the header of the text.
goto se37 exicute fm,
by giving those values
2009 Feb 17 7:25 AM
2009 Feb 17 7:25 AM
see this link:
http://www.sap-img.com/abap/use-fm--read-text-to-read-the-various-text.htm
http://www.sapfans.com/forums/viewtopic.php?f=13&t=310761
CALL FUNCTION 'READ_TEXT'
EXPORTING
ID = '0001'
LANGUAGE = 'E'
NAME = XNAME
OBJECT = 'VBBP'
TABLES
LINES = i_XTLINE
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
NOT_FOUND = 4
OBJECT = 5
REFERENCE_CHECK = 6.
2009 Feb 17 7:27 AM
Hi,
refer the given below code.
CALL FUNCTION 'READ_TEXT'
EXPORTING
CLIENT = SY-MANDT
id = 'KOPF'uF0E0 these details we will get thru transaction , where we enter these details.
language = 'EN'uF0E0 these details we will get thru transaction , where we enter these details.
name = TNAME "table name
object = 'AUFK' " these details we will get thru transaction , where we enter these details.
* ARCHIVE_HANDLE = 0
* LOCAL_CAT = ' '
IMPORTING
HEADER = HTEXT
tables
lines = LTEXT
* 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.
Thanks
Arun
2009 Feb 17 7:27 AM
go to any text in po or sales or mm03.see the header of the text.
goto se37 exicute fm,
by giving those values
2009 Feb 17 7:28 AM
Hi
Functiionality of READ_TEXT is
IF you give TX id .. it will return text corresponding to particular text id .
For testing purpose take one text id from tcode SE75 and execute the FM
YOu will get text .
2009 Feb 17 7:28 AM
2009 Feb 17 7:30 AM
you can use this a reference.
DATA: BEGIN OF HTEXT.
INCLUDE STRUCTURE THEAD.
DATA: END OF HTEXT.
DATA: BEGIN OF LTEXT OCCURS 50.
INCLUDE STRUCTURE TLINE.
DATA: END OF LTEXT.
DATA: tdname like VBDPA-tdname.
CALL FUNCTION 'READ_TEXT'
EXPORTING
ID = '0001'
LANGUAGE = 'E'
NAME = TDNAME
OBJECT = 'VBBK'
HEADER = HTEXT
TABLES
LINES = LTEXT
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
NOT_FOUND = 4
OBJECT = 5
REFERENCE_CHECK = 6.
regards,
Mon Magallanes
2009 Feb 17 7:30 AM
Try this,
DATA:TEXTNAME LIKE THEAD-TDNAME,
TEXTHEADER LIKE THEAD.
CALL FUNCTION 'READ_TEXT'
EXPORTING NAME = TEXTNAME
LANGUAGE = SY-LANGU
OBJECT = 'TEXT'
ID = 'ST '
IMPORTING HEADER = TEXTHEADER
TABLES LINES = TEXTLINES
EXCEPTIONS OTHERS = 1.
CHECK SY-SUBRC = 0.
Regards,
Joan
2009 Feb 17 7:30 AM
2009 Feb 17 7:41 AM
Hi,
read the documention for the FM..OBJECT, NAME, ID, and LANGUAGEare the mandatory parameters..if u have doubt as to what to pass to this values,refer table STXH to get ur parameters
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |