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

Set parameter id - problem

Former Member
0 Likes
713

Hello all,

I have a custom program ABC which has a process order field at selection screen.

parameters : p_aufnr like afko-aufnr.

I have another ALV custom program XYZ using REUSE_ALV_GRID_DISPLAY FM. In this program I have added a custom button to take the control to program ABC when pressed. I select a line which has a process order number in it and then I press this custom button.

And in the USER_COMMAND I added something like


    when 'BUTTON'.

        read table itab index rs_selfield-tabindex.
         set parameter id 'ANR' field itab-aufnr.
         call transaction 'ABC'.

But the process order number is not passed into the selection screen field of program ABC. I dont know what I am doing wrong. Please help.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
495

Hi Raju,

Try

parameters: p_aufnr type aufnr memory id 'ANR'.

This may work (see below from ABAP Help)

Addition 5

... MEMORY ID pid

Effect

Assigns the memory ID pid to the parameter on theselection screen. This means that when the selection screen appears,the input field contains the last value entered by the user in a fieldwith memory ID pid.

Regards

Gareth

2 REPLIES 2
Read only

Former Member
0 Likes
496

Hi Raju,

Try

parameters: p_aufnr type aufnr memory id 'ANR'.

This may work (see below from ABAP Help)

Addition 5

... MEMORY ID pid

Effect

Assigns the memory ID pid to the parameter on theselection screen. This means that when the selection screen appears,the input field contains the last value entered by the user in a fieldwith memory ID pid.

Regards

Gareth

Read only

Former Member
0 Likes
495

raju,

as mentioned by gareth, use memory id 'ANR' in the program of 'ABC'..and in teh calling program do like this..

when 'BUTTON'.

read table itab index rs_selfield-tabindex.

set parameter id 'ANR' field rs_selfield-value. "which has the order no.

call transaction 'ABC'.

cheers,

Sathish. R