SAP R/3 форум ABAP консультантов
Russian ABAP Developer's Club

Home - FAQ - Search - Memberlist - Usergroups - Profile - Log in to check your private messages - Register - Log in - English
Blogs - Weblogs News

Text elements and text symbols



 
Post new topic   Reply to topic    Russian ABAP Developer's Club Forum Index -> ABAP Dictionary
View previous topic :: View next topic  
Author Message
admin
Администратор
Администратор



Joined: 01 Sep 2007
Posts: 1639

PostPosted: Wed Oct 17, 2007 6:53 pm    Post subject: Text elements and text symbols Reply with quote

I would like to know in which table is stored the information and text elements from any Z program that programmers can define through Go to, text elements, text symbols.

1) A simpler alternative would be:
READ TEXTPOOL <Program Name> INTO itab LANGUAGE sy-langu.

2) In general all the texts are stored in STXH and STXL tables , but the data it not human readable. It is in raw format, which can only be read using FMs like READ_TEXT.

3) READ_TEXT function module

First select corresponding fields of table itab_stxh against pono.
Stxh-tdname (text name) = PO No
Stxh-tdobject (text object) = EKKO
Stxh-tdid (text-id) = f01,f03,f05 (line items of itab)

Loop at itab and pass above arguments u ll get back the text detail of each row of itab ie against each id and put it in a wa having field like tline-tdline..

Code:
REPORT ZREADTEXT.

parameters: po like ekko-ebeln.

data : begin of itab_stxh occurs 0.
include structure stxh.
data : end of itab_stxh.
DATA: wa_TEXT like TLINE occurs 0 with header line.

data : begin of it_text occurs 0,
tdid like itab_stxh-tdid,
tdline like tline-tdline,
end of it_text.

*DATA: it_TEXT like TLINE occurs 0 with header line.

select * into corresponding fields of table itab_stxh from stxh where
tdname = po.


loop at itab_stxh.

CALL FUNCTION 'READ_TEXT'
EXPORTING
* CLIENT = SY-MANDT
id = itab_stxh-tdid
language = sy-langu
name = itab_stxh-tdname
object = itab_stxh-tdobject
* ARCHIVE_HANDLE = 0
* LOCAL_CAT = ' '
* IMPORTING
* HEADER =
tables
lines = wa_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 <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.

loop at wa_text.
MOVE wa_TEXT-TDLINE TO IT_text-TDLINE .
move itab_stxh-tdid to it_text-tdid.
APPEND IT_text .
endloop.

break-point.
write : / itab_stxh-tdid, itab_stxh-tdobject.

endloop.

loop at it_text.
write : / it_text-tdid, it_text-tdline.
endloop.


4) use FM RS_TEXTPOOL_READ
give objectname as Programname
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Russian ABAP Developer's Club Forum Index -> ABAP Dictionary All times are GMT + 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


All product names are trademarks of their respective companies. SAPNET.RU websites are in no way affiliated with SAP AG.
SAP, SAP R/3, R/3 software, mySAP, ABAP, BAPI, xApps, SAP NetWeaver and any other are registered trademarks of SAP AG.
Every effort is made to ensure content integrity. Use information on this site at your own risk.