2010 Jun 21 11:05 AM
I used the demo program BCALV_GRID_EDIT to implement my editable grid and now I got stuck in the
method data_changed, where I do that loop:
LOOP AT rr_data_changed->mt_good_cells INTO ls_mod_cells.
where I check, get the values and modify the cells.
If something is wrong, I call the alv error protocol like this:
CALL METHOD rr_data_changed->add_protocol_entry
EXPORTING
i_msgid = '0K'
i_msgno = '000'
i_msgty = 'E'
i_msgv1 = text-004 "Buchungskreis
i_msgv2 = l_rbukrs
i_msgv3 = text-006 "exisitiert nicht
i_fieldname = ls_mod_cells-fieldname
i_row_id = ls_mod_cells-row_id.
The right wrong value is highlighted in red, the message is displayed, everything works fine until I change the value back to normal.
Then I get a run time error TSV_TNEW_PAGE_ALLOC_FAILED because MT_GOOD_CELLS couldn't be expanded.
It happened in class CL_ALV_CHANGED_DATA_PROTOCOL, in method MODIFY_STYLE in line 41.
append ls_modi to mt_good_cells.
I already tried to debug that method, to see what went wrong, but the debugger doesn't work any more at this point.
I guess I use the method wrong.
Does it has got something to do with
cl_gui_control=>www_active which is not active in my test? (p_loce in BCALV_GRID_EDIT)
I tried already many things with refresh_protocol and protocol_is_visible but the problem does not change.
Any suggestions? Should I simply choose to a message_list class and do the highlighting manually?
My problem is solved, because the method modify_style was the reason for the run time error.
I called for one special field in the loop at mt_good_cells the method modify style
which tried to append a line to it.
append ls_modi to mt_good_cells.
in a loop to change the internal table the loop is based on isn't a good idea.
So the memory ran out and the system hang up when the memory size for the table was overrun.
Thanks for listening, the problem is solved.
2010 Jun 21 1:29 PM
My problem is solved, because the method modify_style was the reason for the run time error.
I called for one special field in the loop at mt_good_cells the method modify style
which tried to append a line to it.
append ls_modi to mt_good_cells.
in a loop to change the internal table the loop is based on isn't a good idea.
So the memory ran out and the system hang up when the memory size for the table was overrun.
Thanks for listening, the problem is solved.
| User | Count |
|---|---|
| 6 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |