Dynamic Email Attachment Name For Received Mails - Process Integration - Community Wiki
Dynamic Email Attachment Name For Received Mails - Process Integration - Community Wiki
Welcome to the new version of SAP Community Wiki: Learn What's New? and what has changed.
Pages / … / Step-by-Step Guides - Connectivity - Main page
When dealing with mail adapters, most often we tend to send or receive mails with attachments that have few concerns that we need to take care of. For instance
attachment filename, content type etc. At times when we receive any mail with attachment, we face the issue with the default name of the attachment, as it is not the
original filename that has been sent as attachment via mail.
Business Case:
Files placed in the sender business system (FTP) are sent as email attachments to the recipients based on payload of the sent message and the email attachment
should have same name of file placed in sender business system. The files that are placed in sender business system are of type flat or xml.
Off target Approach:
For receiver mail adapter choosing Transport Protocol as SMTP and Message Protocol as XIPAYLOAD, then marking Use Mail Package and Keep Attachments
produces a mail attachment with default name e.g.:- untitiled.xml, though we can give any name as a attachment name using standard adapter module
MessageTransformBean, but its not dynamic approach as every time we need to mention the file name in Module Configuration table of Module tab.
Dynamic Approach:
Design the objects as we do for normal email approach, source structure holds the structure of sender payload, since we are using mail package we need download
the SAP Note 748024 (User required) and import it using external definition. The following is the target structure of the imported xsd.
https://wiki.scn.sap.com/wiki/display/XI/Dynamic+Email+Attachment+name+for+Received+Mails 2/4
4/5/2020 Dynamic Email Attachment name for Received Mails - Process Integration - Community Wiki
xi_stepbystep_adapters bc-xi-con-mai
7 Comments
Unknown User (sqfbkkg)
And how you relize the mapping of the content field of the mail???
Thanks
Edwin Theuns
Hi,
how is the mapping for the field Content relized?and the rest of the design(Interface Mapping, etc?
Greetings
https://wiki.scn.sap.com/wiki/display/XI/Dynamic+Email+Attachment+name+for+Received+Mails 3/4
4/5/2020 Dynamic Email Attachment name for Received Mails - Process Integration - Community Wiki
Justin George
One important configuration missing in the blog is to check the ASMA settings at the receiver adapter also. Without that, this will not work.
Mark Bernabe
Hi,
Thanks. I followed the steps and it worked. The same filename was sent as E-Mail however, the contents are gone. Has anyone encountered the same
problem?
Mark
Hi,
I have followed as above but the content in the file is blank. How to rectify it.
Without mapping we have gone for using script in File sender channel but the script is sending same files mutliple times instead of one time.
Thanks,
Sunil
https://wiki.scn.sap.com/wiki/display/XI/Dynamic+Email+Attachment+name+for+Received+Mails 4/4