cancel
Showing results for 
Search instead for 
Did you mean: 

Using keys with ItemListBoxes.

Former Member
0 Kudos

Hi Everyone,

I want the same functionality as 'drop down by key' (which is used in drop downs) available in ItemListBoxes.

Eg: I have a list box of country names and when the user selects one or more countries i should be able to get the country codes.

Thanks and Regards,

Sindhu JR.

Accepted Solutions (0)

Answers (2)

Answers (2)

thomas_jung
Developer Advocate
Developer Advocate
0 Kudos

Unlike the RadioButton and CheckBox, there are not two separate (ByKey and ByIndex) UI elments for the ItemListBox. Therefore you always have to use the get_selected* approach as though it was a ByIndex UI element.

Former Member
0 Kudos

hi ,

did u try to follow this ? read the context attribute for Country name using 'get attribute'



*   get single attribute
    lo_el_cn_role->get_attribute(
      EXPORTING
        name =  `COUNTRY_DESC`
      IMPORTING
        value = lv_desc ).

u can do it by control wizard or pressing CTRL + F7 and thn click on the radio button Read Context Node/Attribute

thn u can use the select query to

fetch the country code where county name is lv_desc.

rgds,

amit