08-02-2022 1:11 PM
Hello everyone,
the task is to allow users to enter numeric values and by pressing Enter or clicking some button, to calculate that value in another column.
TYPES: BEGIN OF ls_invent_alv,<br> werks TYPE iseg-werks,<br> name1 TYPE t001w-name1,<br> wekgr TYPE maw1-wekgr,<br> eknam TYPE t024-eknam,<br> matkl TYPE mara-matkl,<br> wgbez TYPE t023t-wgbez,<br> matnr TYPE iseg-matnr,<br> maktx TYPE makt-maktx,<br> netwr TYPE vbrp-netwr,<br> budat TYPE iseg-budat,<br> dmbtr1 TYPE mseg-dmbtr,<br> dmbtr2 TYPE mseg-dmbtr,<br> dmbtr3 TYPE mseg-dmbtr,<br> dmbtr4 TYPE mseg-dmbtr,<br> sumdmb TYPE mseg-dmbtr,<br> decres TYPE p DECIMALS 2,<br> END OF ls_invent_alv.<br>DATA: gt_invent TYPE STANDARD TABLE OF ls_invent_alv,<br> wa_invent LIKE LINE OF gt_invent.
This is my table, which is filled with some data.
This is how it should look like:
on the left columns, data, which is gathered from tables, on the left side (after first green column) are the columns, which should be allow for users to enter value and in green columns, they should be calculated.
Any ideas of how to do this? I have read somethig about REUSE_ALV_GRID_DISPLAY_LVC FM, but have no idea of how to implement this to my program.
08-02-2022 1:49 PM
Don't use the FM. Use CL_GUI_ALV_GRID.
Try searching with keywords CL_GUI_ALV_GRID and editable. Also look at demo program BCALV_EDIT_02
08-02-2022 5:02 PM
All REUSE_ALV* function modules have the edit capability, but better use CL_GUI_ALV_GRID.
08-03-2022 5:23 AM
sandra.rossi matthew.billingham
Could you please, send me a simple example code for CL_GUI_ALV_GRID?
08-03-2022 8:00 AM
08-03-2022 9:45 AM
08-03-2022 9:45 AM
Never mind, I have done this. Thanks for effort! sandra.rossi