cancel
Showing results for 
Search instead for 
Did you mean: 

ABAP proxy to mail scenario (html body + pdf attachment)

Former Member
0 Kudos

Hi experts,

I'm using ABAP proxy to mail scenario with mail package (so we can determine the sender and receiver dinamically).

Now we're facing some problems about how to send and email with  body + pdf attachment.

The email body must have some pictures and some plaint text,  with a specific format (one logo must be in the bottom left corner, the plain text must be centered and another picture must be on the top right corner...) so i think we need html language to achieve this requirement.

Also, we need to send a PDF attachment which comes in binary mode.

How to achieve this?

I have been looking  information and threads but i'm not sure how to do the mapping and receiver mail adapter configuration in order to specify the body + attachment.

The proxy call will send the information like the mail package definition:

<?xml version="1.0" encoding="UTF-8"?>

<ns:Mail xmlns:ns="http://sap.com/xi/XI/Mail/30">

<Subject>MySubject</Subject>

  <From>me@me.com</From>

  <To>you@you.com</To>

  <Reply_To />

  <Content_Type>¿html, boundaty, binary?</Content_Type>

  <Content>

¿HTML Content + PDF attachment in binary mode?

  </Content>

</ns:Mail>

Please suggest.

Thanks & Regards

Accepted Solutions (1)

Accepted Solutions (1)

former_member184681
Active Contributor
0 Kudos

Hi,

Check this blog:

Credits goes to Michal Krawczyk.

Regards,

Greg

Answers (1)

Answers (1)

iaki_vila
Active Contributor
0 Kudos

Hi José Miguel,

I haven't tried with ABAP Proxy, but i have tried to consume a SOAP PI service in ECC and to send attachments. Therefore, in PI you can set Keep Attachmenst in Sender SOAP and Receiver Mail. In PI you take its wsdl to be consumed in ECC.

If you can't do it with ABAP proxy you can try my option, but it would be better if you can do it directly with ABAP proxy.

Hope this helps.

Regards.