05-11-2011 6:41 AM
Hi All,
I want to send mail from SAP to External mail ID's for multiple Users.The program is ok.
But I want to send this to Multiple external Mail id's. Where should I assign this receivers list. Pls advise.
What is the transaction to assign multiple receivers.?
CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
DOCUMENT_DATA = GD_DOC_DATA
PUT_IN_OUTBOX = 'X'
COMMIT_WORK = ''
TABLES
PACKING_LIST = IT_PACKING_LIST
CONTENTS_TXT = IT_MESSAGE
RECEIVERS = IT_RECEIVERS
EXCEPTIONS
TOO_MANY_RECEIVERS = 1
DOCUMENT_NOT_SENT = 2
DOCUMENT_TYPE_NOT_EXIST = 3
OPERATION_NO_AUTHORIZATION = 4
PARAMETER_ERROR = 5
X_ERROR = 6
ENQUEUE_ERROR = 7
OTHERS = 8.
Thank You.
Pranitha.
05-11-2011 6:46 AM
Hi
since you have as part of the parameters "IT_RECEIVERS" you can append multiple recipients using that. If you have a distribution list I think you need to use the function module SO_DLI_LIST_READ_XDL first.
05-11-2011 6:47 AM
Hi,
Populate 'IT_RECEIVERS' with the multiple mail ID's ..
loop at mail_list.
IT_RECEIVERS-RECEIVER = mail_list-mailid. " mail ID
IT_RECEIVERS-REC_TYPE = 'U'.
append IT_RECEIVERS.
endloop.
Regards,
Srini.
05-11-2011 6:54 AM
IT_RECEIVERS parameters needs to be passed as shown below.
wa_receivers-receiver = "..........External mail id".
wa_receivers-rec_type = 'U'.
wa_receivers-express = 'X'.
APPEND wa_receivers TO lt_receivers.
CLEAR wa_receivers.
Once mail is triggered to the external mail id's, check the mail is transferred from SAP or not using the tcode SCOT.
In SCOT,follow the path UTILITIES-> Overview of send orders.
Regards,
Satish Kanteti
05-11-2011 7:11 AM
Hi,
Assign receiving type as 'U' instead of 'B'. It will work definitely.
Ram.