2009 Oct 28 1:25 PM
Hi All,
i used REUSE_ALV_GRID_DISPLAY and make some fields editable on my output by the hepl of field catalog parameter 'EDIT'.
but i want i press save i want to know what data has been changed.
how i can find the exact lines which are change and what is the change.
Regards,
Himanshu Sharma
2009 Oct 28 2:24 PM
HI,
One way is to compare the old values and the new values by storing both the values in an internal table and checking record by record.
Other way is to select the record and then edit it. Then on saving the report all the selected rows alone would get saved.
For alv layout add this.
gs_layout-box_fieldname = 'SEL'.
Add this gs_layout in the alv function module.
In the alv internal table add another field SEL with char 1.
So the selected records would have 'X' in this field SEL.
Hope this helps.
Thanks,
HArini
2009 Oct 28 1:30 PM
Hi
U need to check the "old" values (loaded before displaying them by ALV) and the "new" ones (after displaying them by ALV), and find out the differences.
Max
2009 Oct 28 1:33 PM
hi thanks for the answer but what if there are 1000000 records in the output and only 5 records are changed then its a very long proces to check all the records is there any meathod or parameter which give me the value of changed record.
2009 Oct 28 1:41 PM
Hi
So instead of use the fm GRID, use OOP, in this way u can catch the event triggered as soon as a field is changed
Max
2009 Oct 28 2:11 PM
Hi.
You could sort the ALV-table by last-changed-timestamp and colour the changed fields.
/Tom
2009 Oct 28 2:24 PM
HI,
One way is to compare the old values and the new values by storing both the values in an internal table and checking record by record.
Other way is to select the record and then edit it. Then on saving the report all the selected rows alone would get saved.
For alv layout add this.
gs_layout-box_fieldname = 'SEL'.
Add this gs_layout in the alv function module.
In the alv internal table add another field SEL with char 1.
So the selected records would have 'X' in this field SEL.
Hope this helps.
Thanks,
HArini