cancel
Showing results for 
Search instead for 
Did you mean: 

Drop Down in WebDynpro ABAP

Harsh_Bansal
Contributor
0 Kudos

Hi All,

I have created a WebDynpro application which as 12 Drop Down fields. I have used Drop Down by index.

The issue is for out of 12 of these, four fields show just blank values at runtime in place of proper values which I filled in the internal table for that drop down field.

If internal table had let's say 5 values, then drop down display 5 blank values and so on.

I have used same logic for all these 12 fields but it works for only 8 - 

* navigate from <CONTEXT> to <REV_TYPE_NODE> via lead selection
   lo_node = wd_context->path_get_node( path = `HEAD.REVTYPE_NODE` ).
   REFRESH: li_reviewtype.
   APPEND INITIAL LINE TO li_reviewtype.

   CLEAR: lwa_reviewtype.
   lwa_reviewtype-reviewtype = 'Peer'.
   APPEND lwa_reviewtype TO li_reviewtype.

   CLEAR: lwa_reviewtype.
   lwa_reviewtype-reviewtype = 'Group'.
   APPEND lwa_reviewtype TO li_reviewtype.

   lo_node->bind_table( li_reviewtype ).

I tried debugging, values get properly filled in the table and binding also happens successfully.

Can someone please guide me out of this.

Please find attached the screenshot of output for better understanding.

Thanks in advance.

Regards,

Harsh Bansal

Accepted Solutions (0)

Answers (4)

Answers (4)

manigandan_d2
Explorer
0 Kudos

Please try with below code.

REFRESH: li_reviewtype.
   APPEND INITIAL LINE TO li_reviewtype.

   CLEAR: lwa_reviewtype.
   lwa_reviewtype-reviewtype = 'Peer'.
   APPEND lwa_reviewtype TO li_reviewtype.

   CLEAR: lwa_reviewtype.
   lwa_reviewtype-reviewtype = 'Group'.
   APPEND lwa_reviewtype TO li_reviewtype.


lo_node =  wd_context->get_child_node( name = wd_this->wdctx _XXXXX  ).

lo_node->bind_table( li_reviewtype ).

Enter the XXXXX as the node name which you binded to the drop down..

Regards,

Manigandan D

chengalarayulu
Active Contributor
0 Kudos

Are you sure that values populating to that nodes in the above mentioned scenerio?

i mean to say, if you are populating the values to node from SELECT query, then use INTO CORRESPONDING-FIELDS OF.... check.

Nayan
Explorer
0 Kudos

Hi,

What is the input help mode for the attributes assigned to that dropdown's ?

   lo_node = wd_context->path_get_node( path = `HEAD.REVTYPE_NODE` ).

  data: lo_info type ref to if_wd_context_node_info,

          s_value  type wdr_context_attr_value,

           t_value type table of wdr_context_attr_value.

lo_info = lo_node->get_node_info( ).

   s_value-value = '01'

   s_value-text = 'Peer'.

  insert s_value into table t_value.

   s_value-value = '02'

   s_value-text = 'Group'.

  insert s_value into table t_value.

lo_info->set_attribute_value_set (name = NAME_OF_ATTRIBUTE value_set = t_value ).

try this code to assign value set for the attribute just mention attribute name instead of NAME_OF_ATTRIBUTE

Harsh_Bansal
Contributor
0 Kudos

Any suggestion guys?