Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Handling push button in cell level in Alv factory method

Former Member
0 Kudos

Hi,

The following image shows the Alv report using Alv factory method. Using cl_gui_alv_grid there is event with name button_click so we can handle it easily, but

I did not button_click event in the class CL_SALV_EVENTS_TABLE. How to handle the button at cell level. The button here does not signifies the print operation but I just gave a name.

I require handling of the button at column level only using alv factory method. An example with an approach to the solution would be grateful.

Thanks,

Raja Sekhar

1 REPLY 1

Former Member
0 Kudos

if all the function buttons do the same thing, then you need a single function key added to the GUI (copy to your program via SE80 from one of the SALV* programs, using right mouse-click).  Upon function press, call the method to get the row(s) selected (by click on the row) (you will have defined your events and implemented the methods).  Upon selection of the function, evalute the row returned, and determine whether or not allowed, etc., giving appropriate feedback to the user, perhaps with message i016(gr) with your text display like'E'.    If you need to take different actions, again allow the user to select row(s), and press the function they desire.  You would then validate the rows selected, determining whether or not that action was appropriate for the row selected, and provide user feedback via message.

Search with 'SALV Tutorial' for an excellent step-by-step tutorial on SALV by Rich Heilman, or look at the demo programs named like 'SALV*' in SE38 or SE80 for examples of how to do this properly.  Additionally, there are MANY, MANY posts about using SALV; please search the forum.