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

How do I create a sub-menu item

Former Member
0 Likes
2,602

Hi. I'm fairly new to ABAP so be merciful. I would like to know how to create a sub-menu on the menubar(but NOT programatically). I can create regular menu items in the menu editor(I don't know if that's the proper name) but I would like to have the arrow that appears next to the menu items to point to a list of submenu items. Thanks for your time.

KP>

1 ACCEPTED SOLUTION
Read only

Former Member
1,465

Hi Kingsley,

I suppose your doubt is how to create a sub-menu in the output list. You can do that by using the statement

SET PF-STATUS.

so write in the program,

START-OF-SELECTION.

SET PF-STATUS 'MYMENU'.

Now you can do in 2 methods.

1) double click on 'MYMENU'. It will go Menu Painter.

There will be Menu bar, Application toolbar , Function keys.

Click on Menu bar.

Create a Menu , say Menu1. Double click on it and you usually give the FUNCTION CODE & TEXT for creating a menu.

But in this case, you shouldn't give the Function Code.

Just write the text and double click . Now a new menu with Function Code and Text comes. That is it..

Just Give the Function Code and Texts.

Save it and activate it..

2) goto se41 and give the name of the program.

You will be go to Menu Painter.Rest of the steps are same as 1).

In the program, you should write as below.

start-of-selection.

write 'List'.

set pf-status 'MEN'.

at user-command.

case sy-ucomm.

when 'FC2'.

leave program.

endcase.

Hope your query is solved.

Regards,

Sylendra.

Thanks to everyone for your suggestions. Problem solved with Sylendra's solution. I used the first one. I will try the second one in another program so I can have the experience of doing both. Thanks again.

KP>

6 REPLIES 6
Read only

former_member181966
Active Contributor
0 Likes
1,465

You can create Area menue thorugh :SE43

and also you can create menues sub menues using SE41 .. with your program name.

Thanks

Read only

Former Member
0 Likes
1,465

Thank you for your reply. I will try your suggestions. Why doesn't SAP let you create a sub-menu in the same place as the regular menu?

KP>

Read only

Former Member
0 Likes
1,465

Hi KP,

Please have a look at this link.

http://www.henrikfrank.dk/abapexamples/ABAP%20objects%20and%20controls/toolbar_control.htm

Hope this will help.

Regards,

Ferry Lianto

Read only

Former Member
1,466

Hi Kingsley,

I suppose your doubt is how to create a sub-menu in the output list. You can do that by using the statement

SET PF-STATUS.

so write in the program,

START-OF-SELECTION.

SET PF-STATUS 'MYMENU'.

Now you can do in 2 methods.

1) double click on 'MYMENU'. It will go Menu Painter.

There will be Menu bar, Application toolbar , Function keys.

Click on Menu bar.

Create a Menu , say Menu1. Double click on it and you usually give the FUNCTION CODE & TEXT for creating a menu.

But in this case, you shouldn't give the Function Code.

Just write the text and double click . Now a new menu with Function Code and Text comes. That is it..

Just Give the Function Code and Texts.

Save it and activate it..

2) goto se41 and give the name of the program.

You will be go to Menu Painter.Rest of the steps are same as 1).

In the program, you should write as below.

start-of-selection.

write 'List'.

set pf-status 'MEN'.

at user-command.

case sy-ucomm.

when 'FC2'.

leave program.

endcase.

Hope your query is solved.

Regards,

Sylendra.

Read only

Former Member
0 Likes
1,465

Hello Sylandra, I will try your suggestion either tonight(21/03/06) or tormorrow. I have school at night and I will finish early on Wednesday. Don't worry I will put your points. Thank you for your reply.

KP>

Read only

Former Member
0 Likes
1,465

Thanks to everyone for your suggestions. Problem solved with Sylendra's solution. I used the first one. I will try the second one in another program so I can have the experience of doing both. Thanks again.

KP>