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

Incorrect nesting error in user exit include

Former Member
0 Likes
959

Hi,

In one of my requirement I had to add an additional screen using EXIT_SAPMM06E_016, this Function module exists in XM06 Function group, this exit holds an include ZXM06U41.

This function group holds screens, so when I implement a screen and create the PBO module in this particular include, it by default includes

MODULE STATUS_XXX OUTPUT.

ENDMODULE.

When i check this include it says:

Incorrect nesting: Before the statement "MODULE", the structure introduced by "FUNCTION" must be concluded with "ENDFUNCTION".

I have no clue where the open function is?

Your help will be very much appreciated.

Please help.

Thanks,

-Sandeep

1 REPLY 1
Read only

Tamas_Hoznek
Product and Topic Expert
Product and Topic Expert
709

You cannot define a screen module in a function module code.

Refer to available documentation how to properly implement enhancements of this kind. Enhancement name is MM06E005 (in SMOD). Screen definitions and the corresponding modules will happen in function group XM06, not in the exit function module.

Edit: To elaborate, your PBO module will go into include ZXM06ZZZ, or better yet, into new include ZXM06O01 which should be part of ZXM06ZZZ (just to keep the usual naming convention).

Edited by: Tamas Hoznek on Feb 28, 2012 2:51 PM