Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Read_text problem

Former Member
0 Likes
3,427

HI,

I was using read_text to read the text of inforecord. there are 2 types- info memo and purchase order text. While i was getting info memo text using read_text, the other one was not being populated. When I debugged the standard, i saw the standard was also using read_text. That means that the standard screen shows the text but i ma not able to fetch the text using the same function module. So, i check the header of the text. It was showing created by someone else. when i made a small change and tried to read_text again, since now the text was changed by me, it came into my buffer, i was able to read it.

Does anyone know of some trick to fetch texts in such cases when they are stored in some other pool/buffer.

Thanks in advance.

9 REPLIES 9
Read only

Rushikesh_Yeole
Contributor
0 Likes
2,195

Text Name       Inforecord + Pur Org. +0

Language        EN

Text ID         BT

Text Object     EINE

Try This for read_text

Read only

0 Likes
2,195

tried. didnt work

Read only

Former Member
0 Likes
2,195

Hi,

It has nothing to do with buffer. Most likely it should be language problem, eg. if somebody created text in say DE language and you have pass the sy-langu while calling FM READ_TEXT.

if you login with EN language then FM will not be able to read the text. when you modify the text, language will changed to EN then FM will be able to read the text.

Regards

Chudamani Gavel

Read only

0 Likes
2,195

I have already tried this

Read only

michael_kozlowski
Active Contributor
0 Likes
2,195

Try this:

CONCATENATE infnr ekorg esokz werks INTO is_name.

CALL FUNCTION 'READ_TEXT'

  EXPORTING

    id                            = 'BT'

    language                      = 'EN'

    name                          = is_name

    object                        = 'EINE'

  tables

    lines                         = it_lines

          .

Read only

RaymondGiuseppi
Active Contributor
0 Likes
2,195

If you are executing the READ_TEXT during execution of transaction, did you [un]check the bypass buffer option, did you insure not to overwrite memory used by standard transaction, there is only one area in memory for a text (*),

Also if you need two texts, call the FM twice with different value of ID. You could also browse table TXHD to insure you have correct keys/parameters values.

Regards,

Raymond

(*) Look at FM as GET_TEXT_MEMORY, or import CATALOG from memory Id 'SAPLSTXD'.

Read only

0 Likes
2,195

Where do I find the bypass option you are talking about.

Read only

0 Likes
2,195

I'm sure Raymond will correct me if I'm wrong

But I think he is referring to setting LOCAL_CAT = 'X' in the call to READ_TEXT.

Rob

Read only

0 Likes
2,195

Thanks for the reply.

I will try this.