Application Development 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: 

How to get the values in the dropdown listbox for screen field

Former Member
0 Kudos

hi friends !

I have selected dropdown listbox for a field in the screeen. Now, how to pass the possible values into the list. Please give the kind help.

Regards,

-Prasad.

1 ACCEPTED SOLUTION

athavanraja
Active Contributor
0 Kudos

You need to use VRM_SET_VALUES FM.

type-pools: vrm.

data: name type vrm_id, list type vrm_values, value like line of

list.

clear list .

refresh list .

name = 'P_OBJ'. "this is the name of the screen field

value-key = 'A'. value-text = 'Description A'.

append value to list .

value-key = 'B'. value-text = 'Description B'. append value to

list .

call function 'VRM_SET_VALUES'

exporting

id = name

values = list.

Hope this helps.

Regards

Raja

PS: This has been discussed many times here in SDN forum. Please search the forum before posting a new thread.

3 REPLIES 3

athavanraja
Active Contributor
0 Kudos

You need to use VRM_SET_VALUES FM.

type-pools: vrm.

data: name type vrm_id, list type vrm_values, value like line of

list.

clear list .

refresh list .

name = 'P_OBJ'. "this is the name of the screen field

value-key = 'A'. value-text = 'Description A'.

append value to list .

value-key = 'B'. value-text = 'Description B'. append value to

list .

call function 'VRM_SET_VALUES'

exporting

id = name

values = list.

Hope this helps.

Regards

Raja

PS: This has been discussed many times here in SDN forum. Please search the forum before posting a new thread.

Former Member
0 Kudos

Hi Prasad,

As Raja had mentioned, this topic has been discussed many times in this forum in the past. Please make sure that you first search the forum for related topics before you post new ones. that would avoid a lot of redundancy. Anyays, here are some of the topics you can refer to:

http://help.sap.com/saphelp_46c/helpdata/en/9f/dbabe435c111d1829f0000e829fbfe/content.htm

Regards,

Anand Mandalika.

P.S: Please don't forget to reward points and close the thread once your problem is resolved.

Lakshmant1
Active Contributor
0 Kudos

Hi Prasad,

Have a look at demo program DEMO_DYNPRO_DROPDOWN_LISTBOX.

Thanks

Lakshman