Application Development 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: 

Need to Modify 'FORM USEREXIT_SAVE_DOCUMENT_PREPARE.' for Include MV45AFZZ

Former Member
0 Kudos

Hello to all and hope you all are doing well.

I want to put checks before saving a sales order(VA01) and i found this routine 'FORM USEREXIT_SAVE_DOCUMENT_PREPARE' in

userexit include 'MV45AFZZ'. But this routined doesnt contain any area where i can write my abap code for it. I saw a thread with the same name(as mine) which said for an access key to modify the userexit include. Then, whats the use of the userexits if we need an access key ? I am using ECC 6.0 , is there any alternative way to write abap code for the above mentioned routine ?

Thanking in anticipation.

Shehryar Dahar

7 REPLIES 7

gopi_narendra
Active Contributor
0 Kudos

<u><b>in the subroutine just create an Z include and write the code in that include.</b></u>

but to modify this MV45AFZZ u need the access key

Regards

Gopi

Former Member
0 Kudos

Hi,

There is a difference between user exit and customer exit. What ever we are doing at CMOD are customer exits. But the user exits are for routines . That particular perform is called in the sap program.

open up the program MV45afzz from se38, once you give the access key, in the menu options GOTO-> modification operations->insert line area. or switch off assistance. Then you can write the code.

Regards,

Former Member
0 Kudos

Hi Shehryar,

If the coding is done in development server,then you will have ask for the access key as you are the honoured first person to change the code in MV45AFZZ.

The next person who changes this code will have a task created under your request.

Please reward id usefull.

Regards,

Shashank.

0 Kudos

Hello,

yeah. but whats is the alternative for this ? i want to write abap code sumwhere for putting checks before saving a sales order ?

Thanks.

former_member404244
Active Contributor
0 Kudos

Hi,

As the answers given by others write the code in the USEREXIT_SAVE_DOCUMENT_PREPARE only.This exit is called before saving the sales order only.so get the access key and write the code in this exit.

For checking whether this exit is triggering or not.Put a break point on this exit and then run transaction VA01 u will see that this exit will be called before the document is saved.

Regards,

nagaraj

0 Kudos

hello all,

Thanks for your answers. But could someone explain me that why do we need an access key for userexit includes. Then whats the use of userexit if we need an acess key ?

Thanking you

Shehryar Dahar

0 Kudos

Nice Question..

You are on right way...

Keep researching and Keep Asking like this...

Thanks And Regards,

Nirav Parekh