cancel
Showing results for 
Search instead for 
Did you mean: 

multiple select options

Former Member
0 Kudos

Hi,

Based on certain criteria i need to hide/display my selection criteria. Like i have 5 fields like customer, material , plant, chain, date . I need to have select options for all these fields but based on the value selected in the drop down.

I tried by adding one more usage of wdr_select_option in the component, but it doesn't seems to work.

can any one please suggest the procedure for that.

Or

If we can conditionally display the required select options.

Thanks,

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

In the layout, take UIcontainer element

and in the method: WDDOINIT, write the following code for getting select options:

Take one component say select options of type WDR_SELECT_OPTIONS,

method wddoinit .

data :cu type ref to if_wd_component_usage,

ic type ref to iwci_wdr_select_options,

so type ref to if_wd_select_options,

lt_range type ref to data.

  • u need to instantiate usage component

cu = wd_this->wd_cpuse_select_option( ).

if cu->has_active_component( ) ne 'X'.

call method cu->create_component( ).

endif.

  • Create a ref to interface controller ,so that u access its helper classes.

ic = wd_this->wd_cpifc_select_option( ).

  • using the ref initialize selection screen.

so = ic->init_selection_screen( ).

  • create a range

call method so->create_range_table

exporting

i_typename = 'BU_PARTNER'

receiving

rt_range_table = lt_range.

.

  • using the ref to helper class,add a field to the selection screen

call method so->add_selection_field

exporting

i_id = 'BU_PARTNER'

it_result = lt_range.

endmethod.

Edited by: Rammohan Nagam on Mar 18, 2009 2:32 PM

Former Member
0 Kudos

thanks for the reply Rammohan. My question was regarding hiding the other select option based on certain criteria.

Thanks,

abhimanyu_lagishetti7
Active Contributor
0 Kudos

I don't see any visibility property for Seleciton Fields.

You have to delete the selection fields first and add everytime the selection changes in the dropdown

use method REMOVE_ALL_SEL_SCREEN_ITEMS to delete, You hav Readonly parameter instead

of making invisible u can make it readonly in method UPD_SELECTION_FIELD

Abhi