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: 

set a default value for list box

Former Member
0 Kudos

I have created a Table .Table maintain generator has been done.There is one field

which is having a drop down list box. How can i set Default value for it.

I cannot change any code because every thing is system generated one.

Is there anything we can do in the element list for that screen

Please help me out.

Thanks in advance

Kiran

7 REPLIES 7

Former Member
0 Kudos

Hi!

If you are seeing it in the SM30/SM31 transactions, then the default value of the listbox is what the table phisically contains.

You can fill it with a couple of data in 1 step, if you enter the relevant data into an excel column in 20 rows, mark them, copy with Ctrl+C and paste them into the listbox column in SM30.

Regards

Tamá

0 Kudos

when i open through SM30/SM31 the list box is having set of values, but non of them will display.i have to select from list box.so how to set that as default.

Thanks in advance

Former Member
0 Kudos

I think you have created the z table then for that perticular field go to its domain and here in valu range tab just define the fixed value in the table control.

regards

shiba dutta

0 Kudos

In that 7 fixed values. out of that i have to dispay one as default.

Thanks in advance

0 Kudos

Hi Sarath..

If u dont want to change the Code then

in the Screen painter Open the List box attributes and

Assign the default value in the attribute <b>Text </b>. It will be displayed as the Default value.

Otherwise you must code it in PBO Module of the Screen.

Suppose if Listbox field is MARA-MTART.

THEN:

MARA-MTART = 'ROH'.

reward if Helpful.

0 Kudos

I cannot write some field name in the text.

Former Member
0 Kudos

Hi

I think u can do it through graphic CtrlshiftF11 . Try over there

If it is for report u can use the function VRM_SET_VALUES to compile a drop-down list dynamically, all you have to do to set the default value is to set the screen field assigned to the dropdown to the value of the key (after the function call). This will automatically display the text of that key on the screen.

Reward all helpfull answers

Regards

Pavan

Message was edited by:

Pavan praveen