on 07-07-2012 2:04 PM
Hi All,
Actually I am displaying a cloumn with checkbox in ALV Grid.
And I am not able to select multiple checkboxes at a time.
My requirement is to select multiple rows by using Checkboxes in ALV and need to delete those selected rows permanently from database table.
Please help on this .
Thanks in Advance.
Regards,
Pawith.
Hi reddy,
If u want select multiple records from table then u have to put node selection cardinality 0... n.
After selecting check boxes u have to get selected data .. to do this
For check box u have created attribute of type char1...and u biind that node to alv...if it is correct then fallow below steps..
after displaying data select check boxes ..
get data from node using get_static_attributes_table( ) method.
in LOOP statement check the check box attribute value is 'X' then send to another internal table ..
and delete the records from database using internal table..
Regards,
Venkat.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi All,
Actually my problem was how to get those multiple selected checkboxes from ALV.
Thanks in Advance.
Regards,
Pavithranad.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Pavithranad,
To get the records of the selected checkboxes of ALV:
Data : lo_nd_alv type ref to if_wd_context_node,
lt_alv type ref to wd_this->elements_alv.(ALV is the name of the node )
lo_nd_alv = wd_context->get_child_node( 'ALV' )..
lo_nd_alv->get_static_attributes_table( importing table = lt_alv ).
delete lt_alv where check_box is intial. (Check box is the name of the attribute used for checkbox in alv )
1. Delete the records from the table using loop ---- endloop
loop at lt_alv into ls_alv.
delete <DB table name > where field_name = ls_alv-field name.
endloop.
2nd Way.
2. Delete <Data Base Table Name > from table lt_alv.
Thanks & Regards,
Sankar Gelivi
User | Count |
---|---|
94 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.