06-12-2012 2:02 PM
Hi All,
Is it possible to have select/deselect all functionlaity in alv using SALV classes.
Once i select all and click on another button in the status bar it should update some records in the database.
Select/deselect all is an editing functionality so I am not sure whether this is possible in SALV or not.
Please let me know your thoughts on this
Thanks
Bala Duvvuri
06-12-2012 5:55 PM
I have not tried with SALV, but this is very easy to do as OO ALV.... I added the Sel all, Desel All as function buttons, and when the user presses one I loop at the internal table and set my value in the column as 'X' or space as needed....
Why not try this in SALV, and see if you can't achieve the same results by modifying the internal table, and calling the refresh method? I don't see a reason why it would not work.
While SALV is intended to not be editable, one can achieve edited results....by allowing a person to choose a row and press a function button. Then popup a screen, accept the user's input, replace the data into the correct row of the display table and call the refresh method.... goes right around the "not editable" constraints.
06-12-2012 5:55 PM
I have not tried with SALV, but this is very easy to do as OO ALV.... I added the Sel all, Desel All as function buttons, and when the user presses one I loop at the internal table and set my value in the column as 'X' or space as needed....
Why not try this in SALV, and see if you can't achieve the same results by modifying the internal table, and calling the refresh method? I don't see a reason why it would not work.
While SALV is intended to not be editable, one can achieve edited results....by allowing a person to choose a row and press a function button. Then popup a screen, accept the user's input, replace the data into the correct row of the display table and call the refresh method.... goes right around the "not editable" constraints.
06-13-2012 5:54 AM
problem is solved
I created a custom status with custom button for select all and created an event
WHEN 'ALL'.
IF <lfs_edit> IS ASSIGNED.
UNASSIGN <lfs_edit>.
ENDIF.
LOOP AT wt_edit1 ASSIGNING <lfs_edit>.
<lfs_edit>-select = 'X'.
ENDLOOP.
wwo_alv_table->refresh( ).
Thanks
Bala Duvvuri