cancel
Showing results for 
Search instead for 
Did you mean: 

Capture item by Dropdown list in Interactive Form

Former Member
0 Kudos

Hi experts,

I have a problem. I hope to get your suggestion ready.

I created a WebDynpro Abap that contains within it an Adobe Interactive Forms.

With the method wddoinit by the component controller I set all values of the fields into interactive forms correctly.

Inside the form there is a dropdown list which is bind to a table, the list of this dropdown list is filled with properly values of the table which is bind.

When I select a value from the list dropdown I can not capture the selected item by the table corresponding of the data.

Carryover below the code I use to recover (unsuccessfully) the values selected by list dropdown:

DATA:

node_adobe_data TYPE REF TO if_wd_context_node,

node_it0002 TYPE REF TO if_wd_context_node,

node_stato_civile TYPE REF TO if_wd_context_node,

elem_stato_civile TYPE REF TO if_wd_context_element,

stru_stato_civile TYPE wd_this->element_stato_civile.

  • navigate from <CONTEXT> to <ADOBE_DATA> via lead selection

node_adobe_data = wd_context->get_child_node( name = wd_this->wdctx_adobe_data ).

  • navigate from <ADOBE_DATA> to <IT0002> via lead selection

node_it0002 = node_adobe_data->get_child_node( name = wd_this->wdctx_it0002 ).

  • navigate from <IT0002> to <STATO_CIVILE> via lead selection

node_stato_civile = node_it0002->get_child_node( name = wd_this->wdctx_stato_civile ).

  • get element via lead selection

elem_stato_civile = node_stato_civile->get_lead_selection( ).

  • get single attribute

elem_stato_civile->get_static_attributes(

IMPORTING

static_attributes = stru_stato_civile ).

The problem persist also if I use the method GET_LEAD_SELECTION_INDEX.

The return value always is the first item and not what I selected.

I wait trusting your suggestions to solve the problem.

Regards.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Davide,

Maybe you can try to keep your own Index parameter (Integer) to keep track of the selected index.

Then use that parameter to select data from your node:

node_stato_civile->get_static_attributes(
    exporting
      index             = wd_this->lv_index
    importing
      static_attributes = stru_stato_civile
      ).

Hope this helps.

Regards,

Roelof Albers