2014 Feb 06 2:46 AM
Hello Gurus,
I have a requirement of Interactive report ,like on first output list when i click button provided on 22 column of 24 columns i need to go into another list .
So how can i achieve this using set_table_for_first_display, please anyone can provide me sample code.
Thanks & Regards,
2014 Feb 06 3:16 AM
2014 Feb 06 3:16 AM
2014 Feb 06 3:29 AM
Hi,
Hope this example program helps you, once have look.
http://saptechnical.com/Tutorials/ALV/Interactive/oops.htm
-Vijay
2014 Feb 06 3:58 AM
HI,
Use the events of the class CL_GUI_ALV_GRID .
If you need the new screen to be displayed on :
Double click : use the event -> DOUBLE_CLICK
Declare a method like this
DOUBLE_CLICK FOR EVENT DOUBLE_CLICK OF cl_gui_alv_grid
IMPORTING es_row_no.
Single (Button )click : use the event -> BUTTON_CLICK
Declare a method like this
BUTTON_CLICK FOR EVENT BUTTON_CLICK OF cl_gui_alv_grid
IMPORTING es_row_no.
or
Make the column as hotspot : use the event -> HOTSPOT_CLICK.
Declare a method like this
HOTSPOT_CLICK FOR EVENT HOTSPOT_CLICK OF cl_gui_alv_grid
IMPORTING es_row_no.
And of course the set handler for registering methods.
SET HANDLER Class_object->DOUBLE_CLICK FOR Grid_object.
or
SET HANDLER Class_object->BUTTON_CLICK FOR Grid_object.
or
SET HANDLER Class_object->HOTSPOT_CLICK FOR Grid_object.
Hope this helps.
Regards.
2014 Feb 06 12:09 PM
you have events in that same class
you need to handle the event of your requirement ..
create a local class or in your local class , create a handler for this event ,
and after setting table for first display , register for this event.
generally event when raised carries some info with it , based on the object .
in your case you will be getting row number and column number.
in your event handler method , this data will be available , and use accordingly.
based on the data , trigger new screen.