Receiver Mail Adapter: Formatting the mail content

Dear All,
I'm using a receiver mail adapter. I would like to format the content of the mail using the contents of the XML message. For example:
XML Message
<Order>
  <OrderID>1234</OrderID>
  <CustomerName>Sandeep Joseph</CustomerName>
  <NetValue>7467.99</NetValue>
  <Link>http://locahost:7000?OrderID=1234</Link>
</Order>
Mail Content
Dear Approver,
Please approve the Order - 1234, Customer - Sandeep Joseph
Link: http://locahost:7000?OrderID=1234
Thanks,
Are there any modules which would help formatting to this extend? Or any other mechanism?
Thanks,
Sandeep

The easiest means is to use XSL mapping and create the Content Type as HTML and emded the cotent within HTML tags.
One such example is shown by Praskash in this blog,
/people/community.user/blog/2006/09/07/email-reporting
/people/community.user/blog/2006/09/08/email-report-as-attachment-excelword
If you use the Mail Package option then you can also wite a UDF in your mapping that will populate the content field. For every newline you can use the java new line \n and so on.
Regards
Bhavesh

Similar Messages

  • Looking for .XSD for mail for sending the mail through mail adapter

    Hi Experts,
                      I am looking for .XSD file for sending mail.I am using Mail adapter to send mail to report error occur on creating PO document in my scenario to a specified department's email id.I searched for many blogs but not get any .XSD file for email.Looking for a suugesstion.
    Thanks
    Deepak

    Do you have S -user name and password? If not then never mind, Copy the below XSD, I took it from the link which I gave to you.
    <?xml version="1.0" encoding="utf-8" ?>
    <xs:schema targetNamespace="http://sap.com/xi/XI/Mail/30"
      xmlns:xi="http://sap.com/xi/XI/Mail/30"
      xmlns:xs="http://www.w3.org/2001/XMLSchema">
      <xs:element name="Mail">
        <xs:annotation>
          <xs:documentation>Mail package for XI - Mail Adapter</xs:documentation>
        </xs:annotation>
        <xs:complexType>
          <xs:sequence>
            <xs:element name="Subject" type="xs:string" minOccurs="0"/>
            <xs:element name="From" type="xs:string" minOccurs="0"/>
            <xs:element name="To" type="xs:string" minOccurs="0"/>
            <xs:element name="Reply_To" type="xs:string" minOccurs="0"/>
            <xs:element name="Content_Type" type="xs:string" minOccurs="0"/>
            <xs:element name="Date" type="xs:dateTime" minOccurs="0"/>
            <xs:element name="Message_ID" type="xs:string" minOccurs="0"/>
            <xs:element name="X_Mailer" type="xs:string" minOccurs="0"/>
            <xs:element name="Content" minOccurs="0">
              <xs:annotation>
                <xs:documentation>any type</xs:documentation>
              </xs:annotation>
            </xs:element>
          </xs:sequence>
          <xs:attribute name="encoding" type="xs:string"/>
        </xs:complexType>
      </xs:element>
      <xs:element name="MailReceipt">
        <xs:annotation>
          <xs:documentation>Mail Receipt for XI - Mail Adaper</xs:documentation>
        </xs:annotation>
        <xs:complexType>
          <xs:sequence>
            <xs:element name="Server" type="xs:string"/>
            <xs:element name="Format" type="xs:string"/>
            <xs:element name="UseMailPackage" type="xs:boolean"/>
            <xs:element name="Encoding" type="xs:string"/>
            <xs:element name="Subject" type="xs:string" minOccurs="0"/>
            <xs:element name="From" type="xs:dateTime" minOccurs="0"/>
            <xs:element name="To" type="xs:string" minOccurs="0"/>
            <xs:element name="Date" type="xs:dateTime" minOccurs="0"/>
          </xs:sequence>
        </xs:complexType>
      </xs:element>
    </xs:schema>

  • Formating the mail body

    Hi to all
    Is it possible to format the mail body that we create using FM 'SO_NEW_DOCUMENT_ATT_SEND_API1' like a rich user interface?
    Kindly suggest.
    Thanks & Regards
    Vipin

    Its possible to give html tags in the body internal table thereby make it a rich user interface. For html you may need to use document type as HTM.
    I 've given an example in this link. Please have a look.
    Re: Bold, Colors in mail - Urgent
    Rgds,
    TM.

  • Sender Mail adapter get no mails

    Hello,
    we are using the sender mail adapter to receive mails (IDOCS) from a Exchange server.
    A few days it works, but suddenly no mails are received.
    But in RWB the mail adapter status is green and shows, that there are no new mails. But when I check the mail box with OUTLOOK, there are some mails.
    When I deactivate and activate the mail adapter, all mails are read then.
    Pollinterval: 1 minute
    XI: SP10
    Who can help me are had s similar problem?
    Or is it possible to stop/start the mail adapter (or the adapter engine) automaitcally (more like a workarround)
    best regards
    Werner Magerl

    Hi All,
    I chekced your responses and tried accordingly. Our basis team has given me new link now and the error message has changed. I am getting following error message.
    exception caught during processing mail message; java.io.IOException: unexpected login response; read 001F BAD Command received in Invalid state.
    Does anyone have any idea what this error is?
    Thanks in advance,
    Devendra

  • Why wont my mail open? The mail not being able to open is making me not be able to shut down my laptop.

    Why wont my mail open? The mail not being able to open is making me not able to shut down my macbook.

    Press power button down and hold up to 30 secs to force shut down and then start up and see how u goes on ur mail....

  • I am unable to open scanned documents (with .jpg file extension) in my e-mail inbox, on the Mail app on my iPad. Please provide a clear answer. Thanks a lot.

    I am unable to open scanned documents (with .jpg file extension) in my e-mail inbox, on the Mail app on my iPad. Please provide a clear answer. Thanks a lot.

    Can you actually see that the attachment has a .jpg extension?  Some mail systems strip it off (I've seen AOL do that) which makes the attachment difficult to open.

  • I get an error message saying itunes could not sync mail accounts. because the mail accounts are in use by the iPhone.  It asks that i close the mail accounts settings on the iPhone and sync again.  Is it requesting that i delete my email accounts?

    i get an error message saying itunes could not sync mail accounts. because the mail accounts are in use by the iPhone.  It asks that i close the mail accounts settings on the iPhone and sync again.  Is it requesting that i delete my email accounts?

    just as i've posted the same issue here   hope that someone could give us a hand. I have just swtched from nokia to iPhone for my company cell and i have more than 1000 contacts... it would be murder to create those contacts one by one )))))

  • I am sending a mass e-mail out to my mailing list and the mail program gets locked up and stops responding before sending the e-mail?

    I am sending a mass e-mail out to my mailing list and the mail program gets locked up and stops responding before sending the e-mail.  How can I fix this issue?  I have done it in the past successfully.

    Holly, how many are you sending to?
    Are you using the To; or BCC: field?
    Individual names or Groups?
    I suspect one malformed address at the moment without much else to go on.

  • Email attachment name in sender mail adapter to the receiver file adapter

    HI ,
    Ths is regarding email to file scenario. I am trying to create file (in rceiver file adapter) with the same name as the email attachment that i read from mail sender adapter. I want ro use adapter module for this. I could find from blogs that there is module - GetAttachmentName - available that i can use for this in sender mail adapter.
    Can you please let me know what whetehr i neeed to mention any module key and parameters for this.
    I assume , i need to do following steps :Please confirm.
    1. i can use this module - after payload swap module and before standard mail adapter module in sender mail adapter
    2. select ASMA option in advanced tab in sender mail adapter
    3. In receiver file adapter select ASMA option in advanced tab in sender mail adapter
    4. Also select file name option in ASMA in sender mail adapter
    Thanks,
    Vamsi

    Hi Vamsi,
    your scenario is also described here: Re: sender mail adapter - attachment name
    If you use the Module getAttachmentName, which is described here,
    http://wiki.sdn.sap.com/wiki/display/XI/AdapterModulePI7.0GetAttachmentName
    your scenario should work as you described it.
    You just need to make sure that the Attachment Name that you read in the first place, is mapped to the Filename Attribute of the
    Fileadapter (http://sap.com/xi/XI/System/File/FileName).
    regards,
    Daniel

  • Stopping BPM thru a msg received via mail adapter, based on mail content

    Hi,
    I have a scenario where a BPM is used to send document to a 3rd Party system, which ends upon receipt of a Technical message ack (TMA) carrying the Correlation ID in it.
    However, there are instances wherein a duplicate document in sent to the 3rd party and in such cases a TMA is not sent back to XI. Instead an email alert is generated and sent to my inbox indicating that the document being posted by the BPM is a duplicate.
    I want to modify the scenario, so that either of the TMA or the email alert can be used to stop the BPM.
    For sending the mail alert sent by the 3rd party to XI, the mail sender adapter can be used. But the email alerts may be generated for multiple BPMs sending the duplicate documents to the 3rd party system.
    So I need to find a way to
    1. choose the mail sent to correct environment (all emails for test and production are sent to my inbox)
    2. pick the correct alert email and send it to the BPM (alert email contains the Correlation ID in its xml attachment)
    Please advise.
    Thanks and Regards,
    Diptee

    does not seem to be a raliable approach to have ACK --> Mail --> BPM scenario.....why cant the end system send the message directly to the BPM that would be much better design approach.....also what time does it take for the 3rd party to respond back with the Ack message?

  • Formatting the mail content in the workflow email

    Hi,
    In a workflow i am displaying a currency value.I want to format the currency value in the output. For eg: currently in the workflow email a value is displayed as 20000.0000 but i want it to display as 20,000.00 .
            I have written the code in the method of the business object where i fetch this value such that the value is changed to the required format and is placed in the container element. The value of this container element is then displyed in the mail body.
    I checked and the value does change to the required format and it is placed in the container element also in the required format(i.e 20,000.00)  But only in the email output the formatting is lost and  it is displayed in the original format(i.e 20000.0000).
    Is there any other way to format the output of the currency field. I tried changing the data type to a character string but then the comma does not appear on the output.
    Thanks!
    Regards
    Archana

    Hi,
    amount = 20000.0000
    mail_amount is the variable that you'll use in mail body
    p_curr is the  currency you'll use.
    WRITE amount TO mail_amount CURRENCY p_curr RIGHT-JUSTIFIED.

  • Dynamic attachment name with receiver mail adapter and use mail package

    We need to send mapped XML payload as attachment (with dynamic name) to a recepient (recepient email id is part of input xml payload, but not part of the mapped XML payload).
    I could probably do this using the adapter module (as per the following link),
    http://wiki.sdn.sap.com/wiki/display/XI/Adapter%20Module%20PI%207.0%20Set%20Attachment%20Name?bc=true
    I would like to explore if this would be feasible using Mail package and XI payload.I already have a Java mapping that is converting the input XML to required Output format. If I am using Mail package (XI Payload), how do I go about sending this Output XML from java mapping as attachment to email id available in the input payload?

    Hi,
    1) XML payload as attachment (with dynamic name)
    2) recipient (recipient email id is part of input xml payload, but not part of the mapped XML payload)
    These two is possible by using Mail Package. You have a standard xsd for mail package which you can download from the SAP Note 748024.
    The xml created in you java mapping which will be your attachment should be put into the <content> tag of the mail package xml structure. and the file name can be set in the <Content_Type> tag.
    <?xml version="1.0"; encoding="UTF-8"?>
    <p2:Mail xmlns:p2="http://sap.com/xi/XI/Mail/30">
    <Subject>My Invoice</Subject>
    <From>from email address<;/From>
    <To>to email address</To>
    <Content_Type>text/plain;name="MyFile.csv";</Content_Type>  --> file name here
    <Content>123;A49;aaa</Content>   -> attachment xml here
    </p2:Mail>
    And you have to select MailPackage in the receiver mail adapter.
    Regards,
    Aravind

  • DECODING MAIL FROM WEB SERVER IN PLAIN TEXT FORMAT(THE MAIL BEING SENT BY LABVIEW APPLICATION)

    Hi All
    I have a labview application that send mail every hour automatically.
    But actually the mail has to be decoded from the web server(by another application).But now when that application decode the data in the mail(that is send by labview application)its getting some funny characters inside that can not be detected by the decoding application
    (When open the mail no problem.)But actually our goal is to decode the mail from the web server.
    Why the extra characters are appearing when decoding from the server?Is it because of the HTML format?
    Is there option to send the mail in plain text format(not like attachment)?
    In outlook we can change the setting (tools->options->send->mail sending format->....here we can set as HTML format/Plain Text format)
    Like that at the sending time can i chenge the sending option as plain text format in my labview application?
    Thanks...

    smercurio_fc wrote:
    Then it sounds to me like this other application is not decoding the attachment correctly, especially if you looked at the attachment yourself after you received it and verified it's correct.
    No, no, smercurio. This is charcter encoding here. In older versions of LabVIEW you could specify what character encoding to use when sending an email through the SMTP VIs. But that gave problems since people in certain locales used certain characters that where not transfered right when the wrong encoding was specified, and that encoding stuff is not understood by most people at all, so the wrong selected encoding was rather the rule than the exception. In newer versions of LabVIEW do the SMTP VIs handle the encoding automatically based on the currently used locale on the system.
    This change is documented in the Upgrade Notes of LabVIEW and probably happened around LabVIEW 7.1 or 8.0.
    A decent mail client will recognize the encoding and convert it back to whatever is necessary before presenting it to the user. The OPs posters server application obviously isn't a smart mail client but probably just some crude text file parser that has no notion of proper mail character encoding and how to deal with it.
    I would suppose that there is a chance to dig into the SMTP VIs itself and try to manipulate or disable that encoding altogether in there but that may open a whole can of worms somewhere else. The proper way would be to process the incoming mail by a character encoding aware mail client before passing it to the text parser. On Unix setting up something like this would be fairly trivial.
    Rolf Kalbermatter
    Message Edited by rolfk on 01-23-2008 10:21 AM
    Rolf Kalbermatter
    CIT Engineering Netherlands
    a division of Test & Measurement Solutions

  • Receiver Mail Adapter Error ( Dynamic mail address to be used)

    Hi EveryBody,
    I am getting an error in the RWB (Communication Channel Monitoring) as Message processing failed. Cause: com.sap.aii.af.ra.ms.api.RecoverableException: Error: invalid XIMailAdapter channel 'a089879fd0b63a4b92ca72d4a4af2ec4'.Mail is not send to the receiver.I have tried using USE MAIL PACKAGE as base64 and NONE.
    Can somebody help me out in the configuration.

    Hi,
    have u refered the below weblog of michal:
    Mail Adapter (XI) - how to implement dynamic mail address
    /people/michal.krawczyk2/blog/2005/03/07/mail-adapter-xi--how-to-implement-dynamic-mail-address
    Thnx
    Chirag gohil.

  • Receiver Mail adapter with multiple mail ids

    Hi Experts,
    I am doing File to Mail scenario.
    I am generating mail package structure using Java mapping.
    Email is not going to multiple mail ids mentioned in To field.
    I tried with , and ; but for both it is behaving strange:
    When using ,(coma)
    in case of multiple receivers:
    only last mail id will receive mail in Inbox
    when using ;(semicolon)
    Every email id person will receive mail but with same name listed under To: that is last mail id.
    For example:
    To: abc.at.test.com,xyzat.est.com,def.at.est.com
    Then only def.at.test.com will receive mail
    In case of semicolon(;):
    Every mail id will receive mail in Inbox, that is abc.at.test.com,xyz.at.test.com,def.at.test.com
    will get mail in their respective mail box, but all mails will have same TO field: def.at.test.com
    I hope it is cleared.
    If you want I can send outlook mail headers from outlook.
    Best Regards,
    Divyesh

    Hi Divyesh
    Refer the below thread. The same problem was being solved.
    Mail Adapter - Multiple mail ID and multiple mail servers config.
    Here is the Summery:
    WRONG: receiver1@server1;receiver2@server2;
    CORRECT: receiver1@server1;receiver2@server2
    Regards,
    Madan Agrawal

Maybe you are looking for

  • How do you transform a 2d scaled data type to a waveform data type?

    I'm using a daqcard 6024e with labview 6.1 pds. I'm modifying an example VI called Cont Acq to Spreadsheet File.vi. I wanted to run an fft on the data coming from the AI Read VI but that data is a 2d scaled array. The Array to Spreadsheet String VI w

  • PDF Documents Print in SAP

    Hello Everybody, I have PDF documents maintained in DMS and assigned to a material. When a production order is created I have to print the PDF from DMS automatically. Can someone tell me how to do that? What ABAP code is to be written to do that. Ple

  • Depreciation Problem

    Dear All, Here's the case : I run depreciation for 12.2010. Then I made transfer from asset 10010 to 10020 for 30.11.2010. I still see planned depreciation for 10010. When I try to run depreciation again for 12.2010, SAP says it's not necessary. I tr

  • Find space between word with different endings and digit

    Hi, I'm trying to figure out how to find spaces between word and digit. I am limited to use only word 'WORD' (either capital or small caps) with different endings like -ing -s -y and more (using \S+). I wrote something like (?i)(?<=WORD\S+)\s(?=\d+)

  • Ssh, sshd, and Apache Enable OpenSSL pkcs11 Engine by Default on T4, T4+ Platforms (18762585, 18764604)

    Hi, so I followed the advice in ssh, sshd, and Apache Enable OpenSSL pkcs11 Engine by Default on T4, T4+ Platforms (18762585, 18764604) - Oracle® Solari- and turned off UseOpenSSLEngine in /etc/ssh/sshd_config (Solaris 11.2 x86, AES-NI capable Intel