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

populate dropdown list inside table control

Former Member
0 Likes
649

hi, can anyone tell me which lines of codes actually populate the dropdown list inside the table control?

this is the path: 1. inside DWDM

2. under interface elements - table control

thanks. will reward if useful.

4 REPLIES 4
Read only

uwe_schieferstein
Active Contributor
0 Likes
556

Hello Evonne

I have not used table controls for many years but if I remember correctly then you can set in the attributes of the table control field whether it should be of type "dropdown list". If the field is linked to a value table via foreign key or to a domain containing fixed values they should be displayed as dropdown list.

Regards,

Uwe

Read only

0 Likes
556

.

Edited by: Evonne on Jan 15, 2008 7:51 AM

Read only

0 Likes
556

Hi Evonne,

The field which you want as a dropdown should be chosen as a Listbox from the attributes of the screen.

For this to be filled with values, you have to use the Funtion Module : VRM_SET_VALUES in the PBO of the screen.

Here is a smal example of how to use this FM. Implement the same in the PBO of the screen.

TYPE-POOLS : vrm.

PARAMETERS : p_c(5) TYPE c AS LISTBOX VISIBLE LENGTH 5.

DATA : name1 TYPE vrm_id,
       list1 TYPE vrm_values,
       value1 LIKE LINE OF list1.
DATA : n TYPE i.

AT SELECTION-SCREEN OUTPUT.
  name1 = 'P_C'.

  DO 5 TIMES.
    value1-key = n.
    value1-text = n.
    APPEND value1 TO list1.
    n = n + 1.
  ENDDO.

  CALL FUNCTION 'VRM_SET_VALUES'
       EXPORTING
            id     = name1
            values = list1.

Regards

Gopi

Read only

0 Likes
556

Hi evonne.

create a normal dropdown list first . later add the drop down into yr tablecontrol.

Reward point if helped