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

ListBox in tableControl

karuna_gangireddy
Contributor
0 Likes
409

Hi All,

I am facing a issue with the dropdown values in the list box. This is in the module pool programming. I have a table control in which to one of the columns i selected 'LISTBOX' and attributes->program-> input field is checked with 'POSSIBLE'. Also in PBO i have this code.

DATA: name TYPE vrm_id,

list TYPE vrm_values,

list_val LIKE LINE OF list.

name = 'ListBox Data'.

list_val-key = 'ZC'.

list_val-text = 'Freight Service'.

APPEND list_val TO list.

CALL FUNCTION 'VRM_SET_VALUES'

EXPORTING

id = name

values = list

EXCEPTIONS

id_illegal_name = 1

OTHERS = 2.

I can see the values in the list[] but i do not see then on the screen.

Could anyone please suggest if i am missing anythin?

Thanks in advance,

Karuna.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
377

put this under INITIALIZATION.


INITIALIZATION.
name = 'ListBox Data'.
list_val-key = 'ZC'.
list_val-text = 'Freight Service'.
APPEND list_val TO list.

CALL FUNCTION 'VRM_SET_VALUES'
EXPORTING
id = name
values = list
EXCEPTIONS
id_illegal_name = 1
OTHERS = 2.

and one more thing..

the id should be equal to the name of the Listbox Parameter.

if you write:

parameters : p1 as listbox.

then pass

id = 'P1'.

Edited by: soumya prakash mishra on Aug 21, 2009 1:12 AM

1 REPLY 1
Read only

Former Member
0 Likes
378

put this under INITIALIZATION.


INITIALIZATION.
name = 'ListBox Data'.
list_val-key = 'ZC'.
list_val-text = 'Freight Service'.
APPEND list_val TO list.

CALL FUNCTION 'VRM_SET_VALUES'
EXPORTING
id = name
values = list
EXCEPTIONS
id_illegal_name = 1
OTHERS = 2.

and one more thing..

the id should be equal to the name of the Listbox Parameter.

if you write:

parameters : p1 as listbox.

then pass

id = 'P1'.

Edited by: soumya prakash mishra on Aug 21, 2009 1:12 AM