on 01-21-2014 8:23 AM
Hi Experts,
I have a requirement to get all the changed records in alv (on press of an enter), I have used the alv events which gives me only the selected record index But i need to get all the records a user has changed before pressing enter key.
I tried the context log, but it gives me log only of my component's context. It doesnt give the changes done in alv.
Please help
Thanks & Regards,
Tashi
Hi Tashi Norbu,
You can get all the changed records of the ALV table by implementing an event handler method for ON_DATA_CHECK event in the view. When user edits any number of records in the table and finally click on the CHECK button of the ALV Tool Bar then the Event Handler method gets triggered.
So,In the Event handler method, you will have parameter called r_param.
r_param->t_modified_cells --- Gives the Edited Records.
T_INSERTED_ROWS -- Gives Inserted Rows
Hope this will be Helpful for you.
Regards,
Ravikiran.K
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Tashi,
Use get_static_attributes_table method, you can read entire data available in the table.
I am also used like that and its working fine.
Regards,
Kishorekumar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Tashi,
You are right, the data is not transferred yet from alv component to context of your component.
To get data from alv component to your component, please try below steps
- Get the alv model reference and save it in view attribute GO_ALV_MODEL
- write the below code in your event handler method on CellAction
IF wd_this->go_alv_model IS BOUND.
wd_this->go_alv_model->data_check( ).
wd_this->go_alv_model->refresh( ).
ENDIF.
Hope now, you should be having latest data in the context of your component.
Regards,
Rama
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
10 | |
9 | |
9 | |
7 | |
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.