2011 Aug 26 4:18 PM
Hi folks,
I'm just about to give up...
I have a OO-base ALV. I'm using the ALV sort ability for an editable collum. I need to refresh/sort the ALV right after the user has changed a value in that collum by pressing ENTER. As is the ALV will not be sorted unless I press the refresh button. That's exactly what I want to happen when the value is changed by pressing ENTER.
ANY suggestions???
Chears,
Robert
2011 Aug 27 5:45 AM
Hi Robert,
I had encountered this earlier i.e we cannot use grouping/ sort a field if any cell in the grid is editable and not sure we have a solution for this.
You need to manually sort the internal table(sort itab1 by fld1 ) before the final display in alv grid using set_table_for_first_display.
Thanks
2011 Aug 27 5:45 AM
Hi Robert,
I had encountered this earlier i.e we cannot use grouping/ sort a field if any cell in the grid is editable and not sure we have a solution for this.
You need to manually sort the internal table(sort itab1 by fld1 ) before the final display in alv grid using set_table_for_first_display.
Thanks
2011 Aug 27 2:09 PM
Hi,
Try to use the event DATA_CHANGED through a local event handler method.
In that, modify the internal table and sort.
Regards,
Rajesh
2011 Aug 29 6:00 AM
Hi,
in PAI,
if sy-ucomm = space. " For Enter Key.
o_grid->check_changed_data( ). " To captured modified values
now refresh the ALV table.
Check BCALV_EDIT_04 Standard Program.
hope this helps u.,
Thanks & Regards,
Kiran
2011 Aug 29 11:45 AM
While sorting the table in method handle_data_changed might be a solution I finally found out that the table (including all filters and sortcriteria) will be sorted after input when the method flush is called within method handle_data_changed_finished.