cancel
Showing results for 
Search instead for 
Did you mean: 

ALV - can not retrieve content of internal table

former_member199351
Active Participant
0 Kudos

I have implemented the following code in WDDOBEFOREACTION of my view to be able to analyze what user enters in ALV grid (I have set it input enabled) to be able to perform subsequent logic (my node name is cnt_items):

DATA: lo_nd_cnt_items TYPE REF TO if_wd_context_node,

lt_elements TYPE wdr_context_element_set,

lo_elements TYPE REF TO if_wd_context_element,

ls_cnt_items TYPE wd_this->element_cnt_items.

lo_nd_cnt_items = wd_context->get_child_node( name = wd_this->wdctx_cnt_items ).

lt_elements = lo_nd_cnt_items->get_elements( ).

LOOP AT lt_elements INTO lo_elements.

CALL METHOD lo_elements->get_static_attributes

IMPORTING

static_attributes = ls_cnt_items.

ENDLOOP.

However, ls_cnt_items always come back with empty values even though I enter the data in ALV table.

Can someone please show me what I am doing wrong?

Thanks,

Alex

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

You can do in this way.

Create a Event handler method of type event ON_DATA_CHECK from Interface controller.When ever you change the data in the table.You can get the modified data in this method.there you can validate the data.

Thanks

Suman

Answers (1)

Answers (1)

former_member199351
Active Participant
0 Kudos

Hi Suman,

Thanks for the help. It solved the issue. I also realized that the method name had to be DATA_CHECK.

Regards,

Alex