on 06-03-2010 12:43 PM
Hi,
I need to capture the deleted Line item when we use Delete funtion in ALV .Where i am using on_data_check i am getting the index but when i get the component value that time it has been already deleted.So any body help me getting a sample code to get the deleted line item in ALV (When press on Delete button in ALV).
Regards,
Amit
Closed
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Thanks for the reply i have already cheked this thread but not understand clearly, I am getting dump when I use Assign statement.
DATA: x_delete_row LIKE LINE OF r_param->t_deleted_rows.
TYPES t_proj_constr TYPE <Ztable>
FIELD-SYMBOLS: <fs_row> TYPE t_proj_constr.
IF wd_comp_controller->ya_optyp = 'DELETE'. ' this stament is also not clear for me
LOOP AT r_param->t_deleted_rows INTO x_delete_row.
"x_addr_factr ?= x_delete_row-r_value.
ASSIGN x_delete_row-r_value->* TO <fs_row>.
DELETE FROM ycot_proj_constr WHERE plant = <fs_row>-plant
AND yr_nbr = <fs_row>-yr_nbr
AND period = <fs_row>-period
AND billback_pr_fmly = <fs_row>-billback_pr_fmly
AND prd_nm = <fs_row>-prd_nm.
ENDLOOP.
Regards
Amit
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Amit,
I guess the stmt ' IF wd_comp_controller->ya_optyp = 'DELETE' ' is not necessary here.
Please have a look at the following implementation of event handler for on_data_check.
FIELD-SYMBOLS <deleted_row> LIKE LINE OF r_param->t_deleted_rows.
DATA isflight TYPE REF TO ig_componentcontroller=>element_node_flighttab.
LOOP AT r_param->t_deleted_rows ASSIGNING <deleted_row>.
isflight ?= <deleted_row>-r_value.
ENDLOOP.
t_deleted_rows will have all deleted rows and the type of each row would be the structure type of the context node which is mapped to alv table.
so in the above code, isflight is a reference to the element of context node which is mapped to alv table.
Hope this will help!
Regards,
Srilatha
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
10 | |
7 | |
6 | |
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.