2007 Jun 06 8:03 AM
Hi,
i have created an alv using oops method. in the list we have a coloumn for new values wherein the user can put values from the dropdown/ edit manually.
after putting the new values in place we want to save these values in the database.
but when iam saving, these new values are not populating in the internal table and thats why not getting saved correctly.
can anybody tell me what to do.
thank you,
sharad
2007 Jun 06 8:06 AM
2007 Jun 06 8:06 AM
2007 Jun 06 9:23 AM
yes, saving is done in module user_command n the pai.
but the changed values are coming in the internal table so it is not saving properly.
2007 Jun 06 9:24 AM
yes, saving is done in module user_command in the pai.
but the changed values are not coming in the internal table so it is not saving properly.
2007 Jun 06 9:51 AM
try putting simillar code as following in PAI before calling save routine
CALL METHOD CL_GUI_CFW=>DISPATCH
importing return_code = return_code.
if return_code <> cl_gui_cfw=>rc_noevent.
" a control event occured => exit PAI
clear g_ok_code.
exit.
endif
2007 Jun 06 11:03 AM
i didnt get what you wanted to say.............
the class that i ve used is cl_gui_alv_grid.....
please tell me clearly....
thanks
2007 Jun 06 1:43 PM
Data you are changing is on the frontend. You need to pass data to backend (server). The static method 'dispatch' of control framework class (CL_GUI_CFW) is used to do this 'manual' synchronization. It is sort of helper method of control framework (which is basis for ALV controls) and is independent of ALV controls (cl_gui_alv_grid etc.) that are used.
Try putting this code as suggested and check.
short code would be (without error handling)
CL_GUI_CFW=>DISPATCH( ).
null
2007 Jun 06 2:16 PM
Hi,
the PAI events are not events of the grid control. I think you must register event with the object and set appropriate handler for processing. In the handler, use method get_current_cell to get and process the value.
Regards,
Clemens