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

CL_GUI_TOOLBAR Programatically Call Button Click

Former Member
0 Likes
1,158

Hi All,

I've a main screen with it's own gui status and buttons.  This screen also has a subscreen with a cl_gui_column_tree / cl_gui_toolbar and it's own gui status and buttons.  When I click on a button on the main screen gui status I would like this to do some processing and then trigger as though I clicked on one of the buttons on the subscreen gui status.

Sadly the cl_gui_toolbar class documentation seems to not be available in english on my system and I'm not having luck finding this issue on scn.

Any help would be greatly appreciated.

-Chris

1 ACCEPTED SOLUTION
Read only

RaymondGiuseppi
Active Contributor
0 Likes
885

Well I suppose you also activated some method to handle events for both occurence of cl_gui_toolbar, why don't you just call the subscreen-toolbar event handler method during execution of mainscreen-toolbar event handler.

Hint: AFAIK no trigger function method (aka a "set_function_selected" method) available (not public at least)

Regards,

Raymond

4 REPLIES 4
Read only

rosenberg_eitan
Active Contributor
0 Likes
885

Hi,

See program RJSD_BCALV_TREE_DEMO.

Try where use for cl_gui_toolbar

Use search operators to narrow down the results:

site:scn.sap.com center cl_gui_toolbar

I have no experience with cl_gui_toolbar

Regards.

Read only

RaymondGiuseppi
Active Contributor
0 Likes
886

Well I suppose you also activated some method to handle events for both occurence of cl_gui_toolbar, why don't you just call the subscreen-toolbar event handler method during execution of mainscreen-toolbar event handler.

Hint: AFAIK no trigger function method (aka a "set_function_selected" method) available (not public at least)

Regards,

Raymond

Read only

0 Likes
885

This is close to what I ended up doing, I also ended up copying some code to multiple locations so the solution was not ideal, but functions.

-Thanks

Read only

0 Likes
885

You could also try to build an unique local class to manage every object, an then use the implicit "sender" parameter in every event.

Regards,

Raymond