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: 

Automatic email after Sale order creation

Former Member
0 Kudos

Hi

I need to send an email to the customer, immediately after the sale order creation. On searching SCN, I got to know that in MV45AFZZ under USEREXIT_SAVE_DOCUMENT we need to add code, as this exit will be invoked each time when we create or change any sales order. My question is do we have any FM to send the email to the particular customer. It would be really helpful if some one can provide the pseudo code.

Regards

Shravan.

3 REPLIES 3

satyabrata_sahoo3
Contributor

kesavadas_thekkillath
Active Contributor
0 Kudos

Why dont you use output types ?

former_member15255
Active Participant
0 Kudos

Hello Shravan Kumar,

There are two ways to handle this.

1) Create a custom table holding the customer number for which the email has to be send after creation of sales order. on creation sales through custom exit MV45AFZZ match the customer of the sales order with custom table if a match found create a mail and send it through function module SO_NEW_DOCUMENT_ATT_SEND_API1

2) Create output types for customer with medium as email.

Regards

Suresh Nair