05-10-2011 10:12 AM
hi all
i have to develope a program in which i need to read data from header note and item text of purchaser requistion.
pl note : From FM read_text and from tab STXH, this is not possible.
pl suggest if there is other way of reading above 2 text from PR TC me53n.
Thanks in adv.
manoj
05-10-2011 10:19 AM
Hi Manoj,
It is possible to read the header note using fm 'Read_text'.
Regards,
Pawan.
05-10-2011 10:27 AM
Hi,
why cannot you use read_text and STXH?
Can you try table STXL?
Regards, Dieter
05-10-2011 11:31 AM
You have to use FM 'READ_TEXT'
and pass language as system language
Text ID = B01
Text Object : EBANH
and pass PR into text name
05-10-2011 11:34 AM
Hi Manoj,
You can do it. Please try again.
CALL FUNCTION 'READ_TEXT'
EXPORTING
ID = B01
LANGUAGE = SY-LANGU
NAME = PR
OBJECT = EBANH
TABLES
LINES = i_header_text
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 NE 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
CALL FUNCTION 'READ_TEXT'
EXPORTING
ID = Z01
LANGUAGE = SY-LANGU
NAME = PR
OBJECT = EBANH
TABLES
LINES = i_request_text
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 NE 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Regards,
XEric
05-10-2011 11:35 AM
Hi Manoj,
How did u come to this conclusion that this is not possible using Read_text ?