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 Parameters

Former Member
0 Likes
1,884

Hi All ;

I have problem with read text parameters.

Now Im using the parameters like below;

name = belnr + gjahr + buzei

call function 'READ_TEXT'

            exporting

            client                = sy-mandt

            id                      = '01'

            language            = sy-langu

            name                 = name

            object               = 'AKKP'

            tables

            lines                 = tab_line[]

But I want to add bukrs to the name variable like that;

name = bukrs + belnr + gjahr + buzei

If I use the name parameter with bukrs the read_text function doesnt work.

Could you help about that ?

Regards

Fırtına



8 REPLIES 8
Read only

Mohamed_Mukhtar
Active Contributor
0 Likes
1,359

Hello Yigit ,

Add zeros to bukrs , belnr , gjahr and buzei and concatenate into name.


CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
   EXPORTING
     INPUT  = bukrs
   IMPORTING
     OUTPUT = bukrs


CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
   EXPORTING
     INPUT  = belnr
   IMPORTING
     OUTPUT = belnr.
.


CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
   EXPORTING
     INPUT  = gjahr
   IMPORTING
     OUTPUT = gjahr
.


CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
   EXPORTING
     INPUT  = buzei
   IMPORTING
     OUTPUT = buzei
.


Concatenate bukrs belnr gjahr buzei into name.



Please pass NAME filed to the READ_TEXT FM.


Thanks

Read only

Former Member
0 Likes
1,359

Hi,

try this:

Regards, Dieter

Read only

0 Likes
1,359

Hi Dieter ;

I tried your solution but it doesnt work.Without bukrs ok , it is working but when I added the bukrs field

the text didnt view.

Regards.

Read only

0 Likes
1,359

Hi,

we don't have text with AKKP in our System.

But try this:

1) create a text for AKKP

2) Have a look via se16 (se16n) into table STXH
3) look into the field NAME.

Please Show us the value of NAME. Perhaps BUKRS isn't included in NAME.

Regeards, Dieter

Read only

rajkumarnarasimman
Active Contributor
0 Likes
1,359

Hi Yigit,

   Kindly check whether we have the standard text(SO10) for the below combination.


Example:

     Belnr  - 0100000000

     Gjahr - 1995

     Buzei - 001

     Bukrs - 0001


     Name = Bukrs + Belnr + Gjahr + Buzei


Append Zero's before concatenation using 'CONVERSION_EXIT_ALPHA_INPUT'


     Standard Text - 000101000000001995001


Check the above Text in SO10, whether it is available or not. If Available, then enter the Standard Text in SO10, click Display button and then press GOTO->Header,


Text Header dialog box will appear with the header details, check the Text ID and Text Object details and pass the same to FM READ_TEXT.


Regards


Rajkumar Narsimman

Read only

Former Member
0 Likes
1,359

Hi Firtina,

you have to do in following way,

data name(21) type c.

name + 0(4) =  bukrs      " bukrs lenth 4

name + 4(10) = belnr     " belnr lenth 10

name + 14(4) = gjahr     " gjahr lenth 4

name + 18(3) = Buzei     " buzei lenth 3

Regards,

Venkat.

Read only

Former Member
0 Likes
1,359


Hi ,

You can take one variable with type as characters as below.

DATA: LF_NAME(200) TYPE C,

          NAME TYPE THEAD-TDNAME.

LF_Name = Bukrs + Belnr + Gjahr + Buzei.

NAME = LF_NAME.

Regards,

Pravin

Read only

RaymondGiuseppi
Active Contributor
0 Likes
1,359

Which text are you trying to read, AKKP "Processing letters of credit" (AKKB-LCNUM) or a document related to accouning document item like BELEG "Document text" (BSEG-BUKRS+BELNR+GJAHR+BUZEI)?

Regards,

Raymond