2009 May 09 12:29 PM
Hi Experts
I am Converting smartform into PDF and send mail to the mailid mentioned in the vendor master.
Upto PDF conversion its working fine, sending mail is the problem here, am getting value for sy-subrc is '2'.
Iam attaching the code below, please suggest me what could be the reason for the error.
call function 'SO_NEW_DOCUMENT_ATT_SEND_API1'
exporting
document_data = wa_doc_chng
put_in_outbox = 'X'
commit_work = 'X'
tables
packing_list = i_objpack
object_header = wa_objhead
contents_bin = i_objbin
contents_txt = i_objtxt
receivers = i_reclist
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.
if sy-subrc <> 0.
write:/ 'Error When Sending the File', sy-subrc.
else.
write:/ 'Mail sent'.
endif.
Thanks in advance
regards
Raja
2009 May 09 12:35 PM
HI,
Check this link..http://docs.google.com/Doc?id=dfv2hmgs_0fm22tggx&hl=en
Check you have correctly populated packing_list table.
[Smartform as a PDF to Mail id |https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/smartformasaPDFtoMailid]
HI,
Check this link..http://docs.google.com/Doc?id=dfv2hmgs_0fm22tggx&hl=en
Check you have correctly populated packing_list table.
[Smartform as a PDF to Mail id |https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/smartformasaPDFtoMailid]
2009 May 09 12:35 PM
HI,
Check this link..http://docs.google.com/Doc?id=dfv2hmgs_0fm22tggx&hl=en
Check you have correctly populated packing_list table.
[Smartform as a PDF to Mail id |https://www.sdn.sap.com/irj/scn/wiki?path=/display/snippets/smartformasaPDFtoMailid]
2009 May 09 2:31 PM
Hi Raja,
If you are executing the program then check your user master in SU01 if any email ID is maintained in that or not.If it is being executed by any other user then check that user id for maintanence of email id.If not maintain the same. This might solve your problem.
Thanks & Regards,
Kalyan.
| User | Count |
|---|---|
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |