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

Display value immediately after selecting value from list box

Former Member
0 Likes
465

Hello,

I have a list box and a output only field in my screen. I want to display a value in the output only field as soon as a vlue is selected from the list box. Now i am doing it by placing a button and selecting a value from the listbox and then clicking on the button displays the value in the output only field. Please help me how to achieve my requirement.

thanks.

1 ACCEPTED SOLUTION
Read only

sridhar_meesala
Active Contributor
0 Likes
408

Hi,

Give a function code to the list box field. Now in the PAI of your screen write the code to display the data in the output only field. See the example code.

In PAI.

CASE sy-ucomm.
 WHEN 'FUN_LIST'.
  IF list_ value = '1'.
   output_field = 'One'.
  ELSEIF list_ value = '2'.
   output_field = 'Two'.
  ENDIF.
ENDCASE.

Thanks,

Sri.

Hello,

I have a list box and a output only field in my screen. I want to display a value in the output only field as soon as a vlue is selected from the list box. Now i am doing it by placing a button and selecting a value from the listbox and then clicking on the button displays the value in the output only field. Please help me how to achieve my requirement.

thanks.

2 REPLIES 2
Read only

anup_deshmukh4
Active Contributor
0 Likes
408

you can use AT SELECTION-SCREEN OUTPUT...!

hope it helps

Read only

sridhar_meesala
Active Contributor
0 Likes
409

Hi,

Give a function code to the list box field. Now in the PAI of your screen write the code to display the data in the output only field. See the example code.

In PAI.

CASE sy-ucomm.
 WHEN 'FUN_LIST'.
  IF list_ value = '1'.
   output_field = 'One'.
  ELSEIF list_ value = '2'.
   output_field = 'Two'.
  ENDIF.
ENDCASE.

Thanks,

Sri.