on 01-07-2009 11:18 AM
Hi All,
Is there any way to sort drop down by key by value. currently it is sorting values in drop down according to keys of those values.
Regards
Amit
Hi Amit,
There is no direct way to sort drop down by key.... you can use drop down by index.... in drop down by key sorting is possible only by creating your own table type if you have access to se11.......
regards
Pranav
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi
to sort ddk u have to create a table type which is not sorted.
for that go to se11->datatype->tabletype
there u have to give line type as WDY_KEY_VALUE,
in KEY TAB
key definition key component key category nonunique
in key components give 'KEY'
in INITIALIZATION AND ACCESS
Standard Table
this will create table type which is not sorted but satandard.
DATA LR_NODE_INFO TYPE REF TO if_wd_context_node_info.
data ls_value type wdy_key_value.
data lt_value_set type 'YOUR TABLE TYPE NAME'.
ls_value-key = 'y'.
ls_value-value = 'yes'.
append ls_value to lt_value_set.
ls_value-key = 'n.
ls_value-value = 'no'.
append ls_value to lt_value_set.
.
here a sort statement or in wtever order u want append the values accordingly.
sort lt_value_set by value.
lr_node_info = wd_context->get_node_info( ).
lr_node_info = lr_node_info->get_child_node( YOUR NODE ).
lr_node_info->set_attribute_value_set( name = 'YOUR ATTRIBUE BINDED TO DDK'
value_set = lt_value_set ).
REgards
govi
drop down by key UI element does not support this thing.
Best regards,
Rohit
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
86 | |
10 | |
9 | |
9 | |
9 | |
6 | |
6 | |
5 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.