09-03-2008 4:45 PM
I want to use cl_gui_alv_grid as a pretty wide open internal table editor.
In the PBO, I
* create the custom container and grid (if they do not exist)
* set the layout variable edit to u2018Xu2019
* populate the outputtable "myinternaltable" and call the set_table_for_first_display method,
Exporting
i_structure_name = u2018myDDICstructu2019
Is_Layout = my_layout
Changing
it_outtab = myInternalTable.
When the grid comes up, I can edit the display, but the changes do not seem to make it back to the itab.
What combination of modes and control structures, etc might I need?
Thanksu2026
u2026Mike
09-03-2008 5:19 PM
That's very helpful. I registered the event and it transfers the data for me now, So then, what does 'edit_mode' do on the layout ?
09-03-2008 4:55 PM
did you set the EDIT EVENT or atleast are you calling the CHECK_CHANGED_DATA method in the PAI.
Register the edit event also for enter or modified then the Data changed event will trigger.
call method g_grid->register_edit_event
exporting
i_event_id = cl_gui_alv_grid=>mc_evt_enter.
For details Just check the programs BCALV_EDIT_01 to BCALV_EDIT_09
09-03-2008 5:19 PM
That's very helpful. I registered the event and it transfers the data for me now, So then, what does 'edit_mode' do on the layout ?
09-03-2008 5:31 PM
it just opens the Columns in the edit mode. But check_changed_data method will transfer the contents back to internal table. It calls the Data_changed event internally.