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

Adding Perform ... Form using explicit enhancement points.

rnb86
Participant
0 Likes
2,408

Hi experts,

i want to add a perform in a standard SAP program using Explicit enhancement points. I have created the first enhancement point under the enhancement spot for the perform declaration. Eg: Perform Sum using ab bc

I have created the second enhancement point in the enhancement spot for implementing that perform and written the code.

WHen i try to activate the program, i get an error saying

" Incorrect nesting: Before the statement "FORM", the structure

introduced by "ENHANCEMENT-SECTION" must be concluded by

"END-ENHANCEMENT-SECTION" . . . . . . . .

Can you please let me know if we can include perform...forms in a standard SAP program. If yes, how.

Edited by: RNB on Jul 9, 2009 4:03 PM

I just commented out the form from the enhancement point and placed the same code inside the insert block. Now the error is gone and i activated the program.

is this practice of putting custom code in the insert block a correct one?

Edited by: RNB on Jul 9, 2009 4:00 PM

Edited by: RNB on Jul 9, 2009 4:03 PM

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,188

hai,

i guess u have used enhancement section and the form statement has come before end enhancement statement ,

so instead of enhancement section create enhancement points for perform and form statment separately

or u can use both in same enhancement point

m.a

4 REPLIES 4
Read only

Former Member
0 Likes
1,189

hai,

i guess u have used enhancement section and the form statement has come before end enhancement statement ,

so instead of enhancement section create enhancement points for perform and form statment separately

or u can use both in same enhancement point

m.a

Read only

Sandra_Rossi
Active Contributor
0 Likes
1,188

Just to know : why do you want to use explicit enhancement points + modification key at the same time ? If you modify the source with a modification key, then you can do whatever you want.

Read only

0 Likes
1,188

Hi Afzal,

to answer your reply, we cannot include any standard report events under the explicit enhancement points. We have to go for implicit enhancement points. I had actually declared a perform statement under the at selection screen on value request event. That was causing the error.

Sandra,

i have the access key, but it is not advisable by our client to use it when we have enhancement points available.

Guys, thanks a lot for replying.

Read only

0 Likes
1,188

>

> I had actually declared a perform statement under the at selection screen on value request event. That was causing the error.

I have 2 comments : you could achieve this only by using the access key, so I think it is not part of your question. A single PERFORM could not be the direct cause of an error. So please explain more the context.

I am still not sure to understand the question, maybe you miss some information :

1) standard explicit enhancement points can be implemented by customers (you must not change the source, but switch to the enhancement mode and then implement the enhancement point (look at [blog|https://www.sdn.sap.com/irj/scn/weblogs?blog=/pub/wlg/12225] [original link is broken] [original link is broken] [original link is broken]; from Thomas Weiss), only if it is not forbidden by sap (flag in enhancement spot definition screen)

2) you can add your own explicit enhancement option in standard code only by using an access key, then you can add it, and implement it.

3) implicit enhancement options are located at beginning/end of forms, function modules, methods, includes, end of data structures, etc. (but not at PBO/PAI/PVR/PVH modules and not at events )