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: 

disable the event on right click in an alv grid

Former Member
0 Kudos

hi,

I´m working with an alv_grid. Within this alv I´d like to disable the event On_RIGHT_CLICK.

After looking around I found the method REG_EVENT_RIGHT_CLICK of class CL_GUI_CONTROL to deregister the right click event, but when I tried to use it a runtime error occured.

Can someone explain to me, which exporting paramter I need to disable the event?

kind regards,

Alexander

8 REPLIES 8

Former Member
0 Kudos

Hi,

You can use this thread to get an idea ,

http://boardreader.com/thread/Disable_ALV_grid_context_menu_6v8rjX17mex.html

Thanks and regards,

Dhaya.G

0 Kudos

Hi,

This thread is related to right clicking on the alv grid.Take a look at this and it may help you.

Thanks,

Rajesh.

krishnendu_laha
Active Contributor
0 Kudos

Hello,

I would suggest to catch the event 'RIGHT_CLICK' through local event handler class

In that method for which event will be registered, you can write to exit

Thanks

Krish

Former Member
0 Kudos

Hi Alexander,

[http://boardreader.com/thread/how_to_disabled_user_settings_in_ALV_by_6rv33X15tuo.html]

The above mentioned thread will definitely help you and you will get your problem resolved.

Thanks and Regards,

Dhaya.G

Former Member
0 Kudos

Hello all,

hmm your ideas where quiet helpful, but it still does not work. After debugging it seems like the event 'right_click' is not raised.

Can you please explain to me, when the event is raised? I interpreted it as right click on the table.

thanks and regards,

Alexander

0 Kudos

Hi,

If your code is working properly for event right click, the event should be triggered whenever you right click on any of the fields in the table.(container for which the event is activated).

Thanks.

Aswath.

Former Member
0 Kudos

Hi all,

sorry for closing this thread before finding a proper answer. As proposed I implemented an event handler, which should react on the event on right_click, but it didn´t work. Only for tasting I changed the event to react on to double_click and it worked. Could someone please explain to me, why the event right_click is not raised?

thanks and regards,

Alexander

Former Member
0 Kudos

Hi,

I tried to catch the wrong event.

The event raised by using right_click on an alv is called: CONTEXT_MENU_REQUEST.

thanks and regards,

Alexander