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

Former Member
0 Likes
1,013

Hi Experts,

I want a listbox in a module pool to be populated with entries in my internal table.

How do we achieve this.

I already have a I/O field on the screen.

Thanks and regards,

Ravi Bhatnagar

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
979

Hi Ravi,

TYPE-POOLS: vrm.

DATA: name TYPE vrm_id,

list TYPE vrm_values,

value LIKE LINE OF list.

PARAMETERS: ps_parm(10) AS LISTBOX VISIBLE LENGTH 10.

AT SELECTION-SCREEN OUTPUT.

name = 'PS_PARM'.

value-key = '1'.

value-text = 'Line 1'.

APPEND value TO list.

value-key = '2'.

value-text = 'Line 2'.

APPEND value TO list.

CALL FUNCTION 'VRM_SET_VALUES'

EXPORTING id = name

values = list.

START-OF-SELECTION.

WRITE: / 'Parameter:', ps_parm.

Reward if useful!

8 REPLIES 8
Read only

Former Member
0 Likes
979

hi,

click on listbox for which field u want listbox.

use function module 'vrm_values' it will help u.

regards

rameshwar

Read only

Former Member
0 Likes
980

Hi Ravi,

TYPE-POOLS: vrm.

DATA: name TYPE vrm_id,

list TYPE vrm_values,

value LIKE LINE OF list.

PARAMETERS: ps_parm(10) AS LISTBOX VISIBLE LENGTH 10.

AT SELECTION-SCREEN OUTPUT.

name = 'PS_PARM'.

value-key = '1'.

value-text = 'Line 1'.

APPEND value TO list.

value-key = '2'.

value-text = 'Line 2'.

APPEND value TO list.

CALL FUNCTION 'VRM_SET_VALUES'

EXPORTING id = name

values = list.

START-OF-SELECTION.

WRITE: / 'Parameter:', ps_parm.

Reward if useful!

Read only

Former Member
0 Likes
979

hi,

try like this using FM VRM_SET_VALUES

DATA: NAME TYPE VRM_ID,

LIST TYPE VRM_VALUES,

VALUE LIKE LINE OF LIST.

PARAMETERS: LSBOX(10)_ AS LISTBOX VISIBLE LENGTH 10.

AT SELECTION-SCREEN OUTPUT.

NAME = 'SURESH'.

VALUE -KEY = '1'.

VALUE-TEXT = 'LINE1'.

APPEND VALUE TO LIST.

VALUE -KEY = '2'.

VALUE-TEXT = 'LINE2'.

APPEND VALUE TO LIST.

CALL FUNCTION VRM_SET_VALUES EXPORTING ID = NAME VALUES = LIST.

if helpful reward some points.

with regards,

Suresh.A

Read only

former_member196299
Active Contributor
0 Likes
979

hi Ravi ,

To solve ur purpose you need to use FM , VRM_SET_VALUES " .

Please check the use of this FM in sample programs :

demo_dynpro_dropdown_listbox

and demo_dropdown_list_box .

You sould be able to do it from here .

Reward if helpful !

Regards,

Ranjita

Read only

Former Member
0 Likes
979

hi

good

TYPE-POOLS: vrm.

DATA: name TYPE vrm_id,

list TYPE vrm_values,

value LIKE LINE OF list.

PARAMETERS: ps_parm(10) AS LISTBOX VISIBLE LENGTH 10.

AT SELECTION-SCREEN OUTPUT.

name = 'PS_PARM'.

value-key = '1'.

value-text = 'Line 1'.

APPEND value TO list.

value-key = '2'.

value-text = 'Line 2'.

APPEND value TO list.

CALL FUNCTION 'VRM_SET_VALUES'

EXPORTING id = name

values = list.

START-OF-SELECTION.

WRITE: / 'Parameter:', ps_parm.

thanks

mrutyun^

Read only

Former Member
0 Likes
979

Hi Experts,

I have designed a infotype but i need to access the HRP1000-STEXT field value to my screen field listbox (subject_area).

how get the values from HRP1000-STEXT.

if i write 'AT SELECTION-SCREEN OUTPUT' system doesn't agree between module/endmodule and parameters also not accepting in module.

how to rectify this problem.pls help me.

thank u.

Read only

Former Member
0 Likes
979

Are u the guy who worked was at client site on Vishal (MAhipalpur)...

Read only

Former Member
0 Likes
979

Hi Ravi,

there are sample programs in SAP itself. go to 'ABAPDOCU' tcode and u can see lot of program. this will help u out

regards

Maneesh Chandran