on 03-19-2007 2:08 PM
Hi.
How to delete row(s) selected in a table?
To elaborate, i have a table and a delete button in the toolbar.
When user selects a row and presses the delete button, the selected rows should be deleted.
thanks in adv.
Hi Aishi.
You can get the actual selected row via the lead selection. If multiple selection is allowed you can get all selected elements as wdr_context_element_set via the method context_node->get_selected_elements( ).
Then loop the set and remove each element from the node:
data:
lt_selected_nodes type wdr_context_element_set,
lr_element TYPE REF TO if_wd_context_node,
lr_node type ref to if_wd_context_node.
lr_node = wd_context->get_child_node( 'YOUR_NODE_NAME' ).
lt_selected_elements = lr_node->get_selected_elements( ).
loop at lt_selected_elements into lr_element.
lr_node->remove_element( lr_element ).
endllop.
Hope this helps.
Cheers,
Sascha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
you can get the selected element from your node as well as all the elements
delete the selection from the table of all entries and then bind the adapted table
to the node (one of the options)
grtz
Koen
edit sorry simultanious post
Message was edited by:
Koen Labie
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.