Application Development and Automation 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: 
Read only

Question on CL_GUI_SIMPLE_TREE

Former Member
0 Likes
481

Instead of selecting the node in a tree control and forcing the user to select a push button or button from the application tool bar, I would like the user to right-click on the node and then select the option required.

The class CL_GUI_SIMPLE_TREE does provide the ability to register the right-click event, but what method is used to register the possible options. Is this possible?

Thanks in advance.

--Vince

1 ACCEPTED SOLUTION
Read only

uwe_schieferstein
Active Contributor
0 Likes
377

Hello Vince

There are always two events required for context menus:

CL_GUI_SIMPLE_TREE

- <b>NODE_CONTEXT_MENU_REQUEST</b> (Context Menu Request for a Node)

- <b>NODE_CONTEXT_MENU_SELECT</b> (Context Menu Entry Selected)

Note the the context menu can be requested on the nodes only (and not the items)

CL_GUI_ALV_GRID

- CONTEXT_MENU_REQUEST

- CONTEXT_MENU_SELECTED

The names of the corresponding methods differ from control to control.

Regards

Uwe

Instead of selecting the node in a tree control and forcing the user to select a push button or button from the application tool bar, I would like the user to right-click on the node and then select the option required.

The class CL_GUI_SIMPLE_TREE does provide the ability to register the right-click event, but what method is used to register the possible options. Is this possible?

Thanks in advance.

--Vince

1 REPLY 1
Read only

uwe_schieferstein
Active Contributor
0 Likes
378

Hello Vince

There are always two events required for context menus:

CL_GUI_SIMPLE_TREE

- <b>NODE_CONTEXT_MENU_REQUEST</b> (Context Menu Request for a Node)

- <b>NODE_CONTEXT_MENU_SELECT</b> (Context Menu Entry Selected)

Note the the context menu can be requested on the nodes only (and not the items)

CL_GUI_ALV_GRID

- CONTEXT_MENU_REQUEST

- CONTEXT_MENU_SELECTED

The names of the corresponding methods differ from control to control.

Regards

Uwe