Matching email Subject with attachment content

Hello All,
Here is my requirement.  I receive and email from a third party.  The emai Subject field has the name of the file that is the attachment.  I need to pick up the email with PI and put the attachment to disk as a file where the name of the file is the "Subject" field of the email.
I have been able to write the attachment to disk as a file using the PayloadSwapBean.  But how do I collect the name of the file from the "Subject" field so I can use it as the name of the file when I write?
Thank you for your assistance.
Rich

Use Dynamic Configuration. The Technical name for this Subject field in mail adapter is SHeaderSUBJECT. You can use it and assign it to FileName parameter of File adapter.
Regards,
Prateek Raj Srivastava

Similar Messages

  • Open Default Email Editor with attachment

    How I open default email editor with attachment. Now I can just open the email editor with mailto,subject,body BUT i cant open it with a attachment, which is in a server.

    es5f2000 wrote:Please don't resurrect zombie threads for "me too" style posts.Hmm, I didnt know this was wrong..
    es5f2000 wrote:If you can use 1.6, Desktop.mail() will at least open the mail application, though it won't let you auto-attach. If you must use 1.5, you may have to hand-roll a solution for each environment you support. I'm not personally aware of any 1.5-compliant library that provides this functionality.Since youve replied, the 1.6 solution of opening an email but without an attachment is not good much use to me, and the creation of various support files and putting them into an attachment is the part of the process that the user has most problems with. So either I could either just create the attachment somewhere and let the customer handle the whole email side of things OR I could make use of the fact that my customers email address is embedded in their license and that an smtp server can be used to send an email from anyone, to open a form for the user to write a problem description and then send it from within my application, but the trouble with this approach is they can't have full control over the email they send.

  • Sending (imap) email draft with attachment created on computer from iphone

    Here's one situation:
    I type up an email and attach an excel file to it, then save it as a draft (in my @me.com drafts).
    The draft email is now visible in the drafts folder on all of my devices: apple mail on my computer that I originally used, my iphone mail drafts, and also by signing on to www.me.com and opening my mail drafts.
    one problem is when you open up an email draft on me.com that was created on a computer mail.app, only to see the message body text lose all of its formatting and appear to be jumbled html.
    My main concern / question is:
    The email draft with attachment appears to be in tact on me.com and on the original computer, but NOT on the iphone. On the iphone, the attachment seems to disappear. Well, not disappear, because it gets replaced by a small rectangle with a blue question mark in it. Basically you cannot view the attachment on the iphone. When you try to send this draft from the iphone, it works, but with jumbled text & no attachment.
    Does anyone have similar problems???

    You are correct about the iDisk app as I have started to use that a little bit more for the sharing purposes.
    However my concern wasn't over the simple task of getting excel files onto the iPhone. It's the fact that email attachments that are either in drafts, OR ALSO if you move a message (with an attachment) into an IMAP email folder, are completely lost when it comes to viewing or sending them from the iPhone. It's stupid - the attachments are still there on my computer (and I think they are still there on the me.com mail viewer as well).
    Sometimes I move certain important work emails (that have attachments) into an IMAP email folder so they can be accessed from anywhere. The fact that the iPhone shows the paperclip and placeholder bit not the actual file is maddening. At least If the attachment was actually SENT from the iPhone, I wouldn't even care about not being able to view it (or even view the File name that is also lost).

  • How to Extract email subject with date from outlook?

    Hello,
    I am new to powershell and was wondering how i can extract the email subject with date for entire last month? i need to generate a report every month end and have to go through all the emails which can be very cumbersome at times. 
    Divyansh 
    Divyansh

     Ok i was able to find the commands but it only list email which are exactly 2 week old .. it does not list the recent items ..  
     Add-type -assembly "Microsoft.Office.Interop.Outlook" | out-null
     $olFolders = "Microsoft.Office.Interop.Outlook.olDefaultFolders" -as [type] 
     $outlook = new-object -comobject outlook.application
     $namespace = $outlook.GetNameSpace("MAPI")
     $folder = $namespace.getDefaultFolder($olFolders::olFolderSentMail)
     $folder.items  | where { $_.SentOn -gt [datetime]"3/1/2014" -AND $_.On -lt [datetime]"3/25/2014" }  | Select-Object -Property Subject, SentOn, Importance, SenderName
    Divyansh

  • PDF forms - Change email subject to field content

    Hi,
    I created a fillable form with a sumbition via email button. When submitting, I need to replace the default email subject "Form Returned: fileName" with the content of a particular field.
    I have no idea where to start. Can you help? THanks, Jp

    wow! that was quick!I'll give it a try,  thank you! 

  • Problems replacing email-subject with SAPConnect

    Hi there,
    I'm sending an order confirmation via SAPConnect as email.
    The order confirmation attaches the email as a *.PDF file.
    Now i'd like to replace the standard subject, that consists in the spool-number and some text from  the message i use.
    So, i went to SPRO, and put 'Your Order: &VBAK-VBELN&' in the mai title. That worked almost properly, because the spool number stayed.
    So, i don't want this spool number output any longer.
    The second point is, that i've tried to replace the standard output of the mail text. I didn't succeed at all.
    So, my question. do you have any ideas to solve my problems?
    Thanks for reply, greetings and happy eastern
    Stefan

    msg.setText("<b>testeeeeeeeeeeeee</b>");R
    eplace that
    bymsg.setContent("<b>testeeeeeeeeeeeee</b>",
    "text/html");
    Thanks DrClap, but that's not exactly the solution I'm looking for, cuz I would have to hard-code that header.
    I have an Email class that I use as a wrapper for the javax.mail API, and I wanna be able to have a setHeader() method that works to enable the users to set the content-type of the text (or HTML) portion of the email, even when there are attachments. How can I achieve this?

  • Regarding email generation with attachment

    Hi Experts,
    1)   Iam sending an email with excel attachment by using the FM "SO_NEW_DOCUMENT_ATT_SEND_API1".
       My problem is for example if i have 5 lines in the email table then these 5 lines are showing in single in the excel.
    How can i rectify this?
    2)  i need to submit the report in the back ground with variant and with out selection screen.How to do this?  
    Rgds,
    Krishna.

    Hi,
      Append each line of ur text seperately in an internal table for eg.  
       objtxt = text-007.
      APPEND objtxt.
      CLEAR objtxt.
      APPEND objtxt.
      objtxt = text-008.
      APPEND objtxt.
      CLEAR objtxt.
      APPEND objtxt.
    *Function module to send email with an attachment
      CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
        EXPORTING
          document_data              = docdata
          put_in_outbox              = 'X'
          commit_work                = 'X'
        TABLES
          packing_list               = objpack
          object_header              = objhead
          contents_bin               = objbin
          contents_txt               = objtxt
          receivers                  = 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.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ELSE.
        MESSAGE s899(m3) WITH 'Mail sent successfully!'.
      ENDIF.
    Then u  ll get the mail the way u designed.
    The answer of ur 2nd question is........
    Specify the selection screen in ur program
    and use FMs 'JOB_OPEN' ,  'JOB_CLOSE' & 'JOB_SUBMT' to schedule the job in the background..
    regards,
    ajit.

  • Need special encoded characters in an Email subject with java 1.3.1_02

    I need to find a way to construct an Email through java with Subject lines built using characters from various Asian encodings. Such as Shift-JIS, Chinese Big5, etc.
    These encodings cannot be in UTF-8 format and must remain in the native character set.
    For testing I have an HTML file constructed using a single line of text with Shift-JIS characters. This file shows properly in web browsers under the Shift-JIS encoding view, and when used to create the body of an email it works perfectly through the DataHandler. However, I cannot get any java Reader to pull the same stream of characters into the Subject of the email. The Subject is always garbage no matter what I do.
    Here is a small code sample with the relevant lines:
    Session session = Session.getDefaultInstance(System.getProperties(), null);
    MimeMessage reSend = new MimeMessage(session);
    Transport ship = session.getTransport();
    BufferedReader s = new BufferedReader(new InputStreamReader(new FileInputStream("C:\\JavaPrograms\\Converted\\JISConv.html"), "SJIS"));
    String resub = s.readLine();
    s.close();
    reSend.setSubject(resub);
    DataHandler collect = new DataHandler(new FileDataSource("C:\\JavaPrograms\\Converted\\JISConv.html"));
    reSend.setDataHandler(collect);
    ship.send(reSend);If I use the "SJIS" encoding in the InputStreamReader above, all characters are shown as "?". If I delete it entirely and use the system default, I get half of the characters and the rest are garbage. I can generate either of those results using various other Japanese and Western encoding definitions.
    I have tried using the above code, also DataHandlers for the Subject, FileReader directly to a String, ByteArrayInputStreams, and StringBuffers. So far everything I try ends up at the same result.
    Can anyone help me out? I really need this to work. If I can get this one encoding to work, then I should be able to program case switches for the other encodings.
    Thanks kindly!
    Kurt Jackson

    First this is an issue with javamail and not with java.
    What makes you think that the mime standard allows what you want to do?
    Both of your 'tests' have been done using alternatives which do support alternative encodings.
    These encodings cannot be in UTF-8 format and must remain in the native character set.That seems rather unlikely to me. Email is transported using one encoding. Certainly SMTP uses only ascii. So what ever you put in there is going to be ASCII no matter what you do to it. I suppose something at the end might try to read it using an alternative encoding but then what happens when someone really wants to send those ASCII characters?
    Mime, I believe, is built on SMTP. And the subject line is still SMTP and thus ASCII.
    Here is one link that covers mime (you might want to check the backing references though.)
    http://www.mindspring.com/~mgrand/mime.html
    I believe there is some sort of official or unofficial standard for doing what you want. I would suggest that you start by getting that first. I would suspect JavaMail doesn't support it.
    Once you have a standard to follow you have the following choices..
    - Modify JavaMail directly to support this (this then becomes a non-distributable solution.)
    - Extend JavaMail do support this. This might or might not be possible.
    - Write your own implementation (don't use JavaMail.)
    - Find another solution from another source that already implements this.

  • When sending an email message with attachment, the message disappears.

    I send and receive messages without any problems but when I try sending a message with an attachment (using Documents to Go, IAnnotate PDF, IWork,) the message somehow disappears (it is not sent to the destination and not listed on "Sent" messages folder. Is anyone having the same issue?

    Hi Jaime,
    Are you saying, you are getting junk characters in the email attachment? Then pls check the following. Since you want to send Japanese fonts, please pass language 'J' in both  objpack-obj_langu = '3' & doc_chng-obj_langu  = '3' instead of '3' please replace it with 'J'.
    Another thing which you may have to check is the SCOT device type. As I understand from my basis colleague, this may also affect your attachment fonts since the emails are sent through SCOT. Go to transaction SCOT-> Settings-> Device types for format conversion. Check whether wrong device type is defined for Japanese there. Hope this helps
    Regards,
    Gokul

  • Mail - Email recieved with Attachment always MIME

    Hello,
    I sent an email with an attachment; it was a .html file, to my iMac Mail program. I am receiving it as a MIME attachment. In fact it does this with other files I have sent with different extensions. I am expecting the attachement to be simply whatever it is I am sending. What am I encountering and how can I fix this.
    Thanks
    iMac OS X 10.5.8
    Mail 3.6
    Sent using Outloook on an XP PC

    Nearly all attachments are a MIME type file, but that is not mentioned when Mail can determine what type of file it is, most often identified by the extension. Calling it simply a MIME attachment means there may be some confusion as to what file format it is actually in.
    With the message open, click on View and place the cursor on Message and choose Raw Source. Is there a header for the attachment that states what type file it is?
    Ernie

  • Email sending with attachment

    Hello,
    I have the following problem :
    I have an .CSV file in a specific Directory, an I want to attached that file in a email in order to send the file to a specific email address.
    The file dimension can be over 200 MB, and my question is if it's exists some restrictions about the file length .
    Please help me with some documentation or something code which fits with my problem.
    Thank you in advance !
    Best regards,
    Daniel.

    Hüseyin Dereli wrote:
    > Hi ,
    >
    > You can use
    >
    > CL_ABAP_GZIP_BINARY_STREAM
    > CL_ABAP_GZIP_TEXT_STREAM
    >
    > to compress your data. Sending that kind of large file via email seems not effective even there are no restrictions. There could be some other way for the related process.
    >
    >
    > Regards
    Hi Daniel,
    I must agree with Hüseyins Statement. I mean do you ever experienced that you have found an 200 mb e-mail in your mailbox?
    I would say you should use the BCS-Class to send an e-mail or some kind of FM like SO_DOCUMENT_SEND_API1.
    Maybe you can find some information of how to send e-mail in this Thread:
    How to add attachments to a mail

  • How to include all of the original text in email replies with attachment

    I am using Mac Mail and I have set up the composing preferences to include all of the original message when responding. This only works so long as I don't send an attachment. If I send an attachment in my reply then the recipient doesn't receive any of the previous text, although the copy in my 'sent' box has it on. I contacted BT and got the following response "If you can send and receive emails including attachments via this software then this indicates that the client configuration is correct, and unfortunately this is as far as we can support Mac Mail. I would suggest you seek further advice from Apple as this may be down to the way you have configured the mail client’s composing preferences. Apple’s help desk will be able to tell you if this is a known issue". I've searched the forum for an answer but couldn't find one, does anyone know how to fix this?

    Annette, welcome to Apple Discussions.
    I don't know what is causing your mail problem, but offer a possible alternate solution.
    Open the email you want to respond to. Then click reply. Then copy the text.
    Then open a new message and paste the copied text. Add your attachment & any additional new text. Then send.
     Cheers, Tom

  • Email reply with attachment in IOS6?

    I noticed that this question has been asked several time but no good answers have been provided. Does anyone in the IOS world know if the IOS 6 programmers will make it possible for us to add attachments to emails when replying or forwarding them? It seems one of those features that should have been included several versions ago but wasn't. It just makes me think whether IOS is really as polished as they want us to think.

    It is very advanced, but it is also very sandboxed and limits file management options for security reasons. To add features such as attachments the iOS has to be modified for security first then adding the feature.

  • Internal email delivery taking very long time (EMAIL WITH attachment sent to large distribution group)

    Hi Fellows
    I am facing an issue with Exchange 2010 SP3 (14.03.0123.003) environment. Internal email sent with attachment to an all employee or large-member distribution group chokes the queue on Hub Transport and takes from 7 to 15 minutes to deliver. during this
    time period users's emails are also delayed because of transport queue. I am trying to diagnose the root cause for this. Your suggessions and insight might be helpful for me to get it over quickly.
    2 x HT + CAS (WNLB)
    2 x MBX (DAG)
    UserBase: 5000+
    Regards.
    J.A

    Hi,
    Generally, a message that has a large attachment or many recipients takes longer for a Hub Transport server to process than a small message that's addressed to only one recipient.
    In Exchange 2010, after a message is received by the Hub Transport server, the message is added to the Submission queue. Messages move from the Submission queue through the categorizer. When the message is categorized, a recipient's e-mail
    address is resolved to an object in Active Directory. This query determines the mailbox associated with that e-mail address and which Mailbox server is hosting that mailbox.
    For more information about Internal message Routing, please refer to the following link.
    http://technet.microsoft.com/en-us/library/bb232193(v=exchg.141).aspx
    In addition, Slow network bandwidth will effect email delivery. We can increase the network bandwidth to take a test. Low computer performance will also affect the delivery. If sending internal email without attachment to all employee or
    large-member distribution group, will they take the same long time to deliver?
    Best Regards.

  • How do I get Payload + Attachment-content into 1 xml using PayloadSwapBean?

    Hi all,
    For a customer I have to poll on a specific email-address on a mailserver until a mailmessage appears, read the attachment (.txt) and transform it to a destination-messagetype. For this purpose, I have used the XI-mailadapter (XIPAYLOAD) and the PayloadSwapBean. I now get the attachment-content in XI and can work with it. So far, so good...
    Now the problem is: I need not only the attachment-content, but also the payload of the mail-xml (with data like sender, CC, subject, body, etc). When I use the PayloadSwapBean, I only get the content from the attachment and I do not get the payload-data. When I do NOT use the PayloadSwapBean, I only get the payload-data and not the attachment-content....
    Is there a way to get both payload (of the email-message) AND attachment-content in 1 file, using this PayloadSwapBean?
    Thanks in advance for your help!
    Regards
    William

    This is not possible. You need a self-written adapter module to achieve this.
    Regards
    Stefan

Maybe you are looking for