09-28-2007 10:31 PM
Hi,
I've got a question on behalf of the event handling of an ALV hotspot. It works perfectly. My problem is that I would like to perform an PBO (to change a pf status accordingly to the content of the selected cell) after an hotspot click. I tried to register the handler method as a system event but it didn't work. Has anyone got an idea?
my coding:
SET HANDLER handle_left_click FOR o_alv.
lw_evnt-eventid = '2'.
lw_evnt-appl_event = c_on.
APPEND lw_evnt TO lt_evnt.
CALL METHOD o_alv->set_registered_events
EXPORTING
events = lt_evnt
EXCEPTIONS
cntl_error = 1
cntl_system_error = 2
illegal_event_combination = 3
OTHERS = 4.
regards Johannes
09-29-2007 12:16 AM
Hi Uter,
Go through class CL_GUI_ALV_GRID.
Create a local class refer to cl_gui_alv_grid class. declare a method to handle hotspot event. Implement the method.
Register this event as SET HANDLER HOTSPOT_CLICK for cl_gui_alv_grid-reference.
Once you done this. IN fieldcatalog mention hotspot = 'X'.
In the above hotspot method store the contect of the selected cell in a global variable.
In PBO before set pf-status check the field content and change the pf-status.
Reward points.
Thanks and Regards,
Sampath.
09-29-2007 12:16 AM
Hi Uter,
Go through class CL_GUI_ALV_GRID.
Create a local class refer to cl_gui_alv_grid class. declare a method to handle hotspot event. Implement the method.
Register this event as SET HANDLER HOTSPOT_CLICK for cl_gui_alv_grid-reference.
Once you done this. IN fieldcatalog mention hotspot = 'X'.
In the above hotspot method store the contect of the selected cell in a global variable.
In PBO before set pf-status check the field content and change the pf-status.
Reward points.
Thanks and Regards,
Sampath.
09-29-2007 8:14 AM
Hi Sampath,
Thanks for your answer. I had done exactly what you suggested before I sent this question. The hotspot click works perfectly but it doesn't send a system event.
I want to run a PBO module of the standard Dynpro after the hotspot click. This only happens if I can register the hotspot event as a system event but this doesn't work.
Has anyone got an idea?
regards Johannes