Skip to Content
Former Member
Jul 14, 2008 at 02:50 PM

Simple Value Help on DropDown via KeyValue leads to short dump after select



I did not succeed in preparing a value help via a key-value table.

Although the DropDown Box shows the entries of the table correctly when selecting (note: onSelect action must be existent) there occurs an error that states that the selected key does not exist. Nevertheless the key does exist, mapped by the set_attribute_value_set method..

Can anyone of you make things more clear for me?

The coding is more or less a 1:1 copy from code that can be found in the sappress book as well as on the internet - only slightly adapted.

I would expect a use-and-forget approach: use the set_attribute_value_set method once and no problems from then. Is it perhaps a bug? I was not able to find related SAP Notes for this.

Find code and error message below.

Best regards,



method WDDOINIT .

DATA: l_node_info TYPE REF TO if_wd_context_node_info,

l_value_set TYPE wdy_key_value_table,

wa_value_set type wdy_key_value,

lo_node TYPE REF TO if_wd_context_node.

lo_node = wd_context->get_child_node( 'NODEXYZ').

l_node_info = lo_node->get_node_info( ).

SELECT * FROM zzt_xyz_ber INTO ls_xyz.

wa_value_set-value = ls_xyz-bezeichnung_lang.

wa_value_set-key = ls_xyz-id.

INSERT wa_value_set INTO TABLE l_value_set.



name = 'ATTRXYZ'

value_set = l_value_set ).



name = `ATTRXYZ`

value = 5 ).



Der Wert selectedKey = "5" der DropDownByKey mit Id "DDK_BERICHT_ID_DETAIL" existiert nicht in der Werteliste und ist auch nicht initial

( The value selectedKey = "5" of UI Element DropDownByKey with ID "..." does not exist in the value list nor is it initial )