Retrieve file name of email attachment

Hi,
it's getting more and more absurd about the fact that it is not possible to get the file name of an email attachment. It's not possible by writing a module (getName(), getContentType() nor getDescription() doesn't work) or by accessing mailadapter specific message attributes.
I mean it's a basic requirement. Why is it so diffcult to implement it???
-Steffen
(frustrated)

Hi,
See the below links
/people/michal.krawczyk2/blog/2005/03/07/mail-adapter-xi--how-to-implement-dynamic-mail-address
http://help.sap.com/saphelp_nw04/helpdata/en/23/c093409c663228e10000000a1550b0/content.htm
http://help.sap.com/saphelp_nw04/helpdata/en/f1/9ef1680efbec4c9656eb028c44ab0b/frameset.htm
http://help.sap.com/saphelp_nw04/helpdata/en/ad/bf93409c663228e10000000a1550b0/frameset.htm
Mail adapter
Regards
Chilla..

Similar Messages

  • Setting up the File Name of email Attachment from Received File Name

    Hello All,
    I have to send the Received File in attachment to an Email if there is any exception. Here I can attach the file, but I cannot set the file name of attachment as the Received File Name. Is there anyway of doing this without using custom pipeline component.
    Here I am using the Orchestration and SMTP Adapter.Any help is greatly appreciated.
    Thanks

    It might work if you use a custom pipeline component on your send port and in the Execute method populate the MIME.FileName property of the body part.
    Something like:
    public IBaseMessage Execute(IPipelineContext pc, IBaseMessage inmsg)
    string filename = inmsg.Context.Read("ReceivedFileName", "http://schemas.microsoft.com/BizTalk/2003/file-properties");
    inmsg.BodyPart.PartProperties.Write( "FileName", "http://schemas.microsoft.com/BizTalk/2003/mime-properties", "filename);
    return inmsg;
    You can take reference from similar post here
    SMTP - Setting attachment filename
    Anther good article with MIME is here
    Setting attachment filename with the SMTP Adapter
    For MIME case your SMTP message construct statement would be like below
    multipartMessage.MessagePart_1= InMSG;
    multipartMessage.MessagePart_2="This is message part2 as a string";
    multipartMessage(SMTP.Subject) ="Email From Dynamic Port";
    multipartMessage(SMTP.From) ="[email protected]";
    multipartMessage(SMTP.SMTPHost) ="yoursmypserver.com";
    multipartMessage.MessagePart_2(MIME.FileName) = "Attachment_Name";
    multipartMessage(SMTP.SMTPAuthenticate) =0;
    Thanks
    Abhishek

  • Dynamic file name of the attachment in sender mail adapter

    Hi
    I have configured a sender mail adapter which receives some attachments.
    Right now the file name of the attachment is hardcoded to "MailAttachment-1" "MailAttachment-2" using the content-description from "AF_Modules/PayloadSwapBean" module.
    I want to set it to dynamic ie. instead of "MailAttachment-1"... i want it with real name of the attach.
    please suggest a solution w/o the need to develop a custom adapter module.
    Thanks!
    Regards,
    Mariano.

    Thanks Prateek,
    Now, i can see that the name of the original file is into the content type named as  text/xml; name"name of the file.xml" when i send the email from outlook.
    If i send it from hotmail, this is not happend.
    Do you know why happend this?
    If i always would have the original name inside the content type, my problem will be solved.
    Edited by: Mariano Vidal on Feb 13, 2009 2:26 PM

  • How to auto save output with date added to file name, and email the results?

    Hi,
    We found a script to capture disk space usage, that automatically places the results into an Excel file. We would like the script to autosave this file to a specific directroy with the date ran as part of teh file name. We would then like these results to
    be emailed to us if possible. (also if possible to highlight cell in red that is 5% OR less available disk space would be great)
    Here is what we have:
    $erroractionpreference = “SilentlyContinue”
    $a = New-Object -comobject Excel.Application
    $a.visible = $True
    $b = $a.Workbooks.Add()
    $c = $b.Worksheets.Item(1)
    $c.Cells.Item(1,1) = “Machine Name”
    $c.Cells.Item(1,2) = “Drive”
    $c.Cells.Item(1,3) = “Total size (GB)”
    $c.Cells.Item(1,4) = “Free Space (GB)”
    $c.Cells.Item(1,5) = “Free Space (%)”
    $c.cells.item(1,6) = "Name "
    $d = $c.UsedRange
    $d.Interior.ColorIndex = 19
    $d.Font.ColorIndex = 11
    $d.Font.Bold = $True
    $d.EntireColumn.AutoFit()
    $intRow = 2
    $colComputers = get-content "C:\Servers.txt"
    foreach ($strComputer in $colComputers)
    $colDisks = get-wmiobject Win32_LogicalDisk -computername $strComputer -Filter “DriveType = 3"
    foreach ($objdisk in $colDisks)
    $c.Cells.Item($intRow, 1) = $strComputer.ToUpper()
    $c.Cells.Item($intRow, 2) = $objDisk.DeviceID
    $c.Cells.Item($intRow, 3) = “{0:N0}” -f ($objDisk.Size/1GB)
    $c.Cells.Item($intRow, 4) = “{0:N0}” -f ($objDisk.FreeSpace/1GB)
    $c.Cells.Item($intRow, 5) = “{0:P0}” -f ([double]$objDisk.FreeSpace/[double]$objDisk.Size)
    $c.cells.item($introw, 6) = $objdisk.volumename
    $intRow = $intRow + 1
    $d.EntireColumn.AutoFit()
    cls
    Thank You

    Hi Phorbin1128,
    The script below amy be helpful for you to save the Excel file with date in filename, and send email with the attachment of the excel report.
    $erroractionpreference = “SilentlyContinue”
    $a = New-Object -comobject Excel.Application
    $a.visible = $True
    $b = $a.Workbooks.Add()
    $c = $b.Worksheets.Item(1)
    $c.Cells.Item(1,1) = “Machine Name”
    $c.Cells.Item(1,2) = “Drive”
    $c.Cells.Item(1,3) = “Total size (GB)”
    $c.Cells.Item(1,4) = “Free Space (GB)”
    $c.Cells.Item(1,5) = “Free Space (%)”
    $c.cells.item(1,6) = "Name "
    $d = $c.UsedRange
    $d.Interior.ColorIndex = 19
    $d.Font.ColorIndex = 11
    $d.Font.Bold = $True
    $d.EntireColumn.AutoFit()
    $intRow = 2
    $colComputers = get-content "C:\Servers.txt"
    foreach ($strComputer in $colComputers)
    $colDisks = get-wmiobject Win32_LogicalDisk -computername $strComputer -Filter “DriveType = 3"
    foreach ($objdisk in $colDisks)
    $c.Cells.Item($intRow, 1) = $strComputer.ToUpper()
    $c.Cells.Item($intRow, 2) = $objDisk.DeviceID
    $c.Cells.Item($intRow, 3) = “{0:N0}” -f ($objDisk.Size/1GB)
    $c.Cells.Item($intRow, 4) = “{0:N0}” -f ($objDisk.FreeSpace/1GB)
    $c.Cells.Item($intRow, 5) = “{0:P0}” -f ([double]$objDisk.FreeSpace/[double]$objDisk.Size)
    $c.cells.item($introw, 6) = $objdisk.volumename
    $intRow = $intRow + 1
    $d.EntireColumn.AutoFit()
    $date=Get-Date -f yyyy-MM-dd
    $filename = "D:\test\"+$date+".xlsx"
    $b.SaveAs($filename)
    $a.Quit()
    Send-MailMessage -SmtpServer xxxxxxxxxx -To [email protected] -From [email protected] -Subject "test mail" -Body "file name is: $new_file" -attachment $filename
    For more detailed information about the cmdlet Send-MailMessage, please refer to this article:
    Send-MailMessage
    I hope this helps.

  • Path and File name of the attachment

    Hello Srm Guys,
    Where should be the Path and File name of the attachment are stored for a shopping card Item.
    Thanks
    Ram

    Hello Ram,
    Execute the function module BBP_PROCDOC_ITEM_GETDETAIL by providing the item guid,object type . Now it will populate the  et_attach importing parameter with the attatchement details.
    In the ET_ATTATCH internal table , the field PHIO_FNAME/PHIO_PATH_FILE provides the physical storage location of the document.
    Hope this info will be helpful.
    Regards,
    Mani

  • Dynamic file name of the attachment in receiver mail adapter

    Hi
    I have configured a receiver mail adapter which receives the payload as an xml attachment.
    Right now the file name of the attachment is hardcoded to "invoice.xml".
    I want to set it to dynamic ie. instead of "invoice.xml"... i want it as "invoice<invoicenumber>.xml".
    Invoice number is present in the payload.
    please suggest a solution w/o the need to develop a custom adapter module.
    Thanks!
    Regards,
    Faria Mithani

    Hi,
    Go through this thread..
    Dynamic  File Name for Receiver File Adapter
    Regards,
    Sarvesh

  • File name of an attachment from HttpURLConnection

    Hi
    I am using HttpURLConnection to download an attachment. Pls someone tell me how to get the file name of the attachment that's to be downloaded.
    Regards
    Faisal

    Well the <b>Content-Disposition</b> header is not always set by the servers when they write the file to the OutputStream. I find that only when the URL itself doesn't given an hint of the File name, a value for <b>Content-Disposition</b> is given.
    For E.g. URL's like <u>http://somehost/context/somefile.zip</u> doesn't give a value for Content-Disposition, where as <u>http://somehost/context/somefile</u> would give a value for <b>Content-Disposition</b>.

  • Cant open a pdf file as an email attachment

    I need help. I can't open a pdf file as an email attachment. It's like my computer doesn't think reader is installed. I can open an existing file through reader. I have deinstalled and reinstalled reader and am getting the same results.

    You can save the attachment and then open it.
    We can try to help but you haven't mentioned what you are using for your email...

  • Getting name of file in an email attachment

    I have a sender mail adapter that has been configured to pick up emails with file attachments from a mail box.
    The mail adapter passes processing onto the PayloadSwapBean and then onto a customised module that processes the file attachment (a CSV file).
    When I use the messaging system i.e. http://xiserver:port/MessagingSystem/monitor/monitor.jsp
    I see the following output, which includes the attachment's file name in the Content-Type i.e. INV_5016888091848_20060912_00001.csv
    Content-Type: application/octet-stream;name="INV_5016888091848_20060912_00001.csv"
    Content-Disposition: attachment;filename="MailMessage.bin"
    Content-Description: MailMessage
    In my customised module I have attempted to pick up this file name from the payload using the "getContentType" method of the "XMLPayload" class but this only returns "application/octet-stream" and does not include the file name.
    Does anyone know how I can get hold of the above file name using the Adapter Framework API?

    Hi,
    Have you tried the following...
    In the adapter module that you wrote, did you try calling the method 'getSupplementalDataNames() ' of the 'ModuleData' class ??
    I am assuming all the attachment details should be available in the enumeration this method returns...please let me know...
    My reasoning that it might work is that the 'PAYLOADswapbean' is somehow reading all the attachments details..which technically we should be able to do if we wrote an adapter module on our own....
    I did not get time to try this out..please check if this helps....
    Thanks.

  • Random file name when saving attachment in email

    I access my email account with Safari and when i try to save as an attachment, the original file name does not automatically appear in the save as dialogue box. Some random file name appears instead n its very annoying. Can anyone help?
    Thanks!

    Ksun_17 wrote:
    ... when i try to save as an attachment ...
    Try to save what?  The entire email message?  Somthing that is embedded in the email message?
    Anyway, why would you use Safari to access your email instead of Apple's Mail application?

  • Dynamic file name as mail attachment in receiver Mail Adapter?

    Hi,
    Can any one tell the possibility of attaching file as a mail attachment without using mail Package with dynamic filename.
    Business requirement is to send error response as mail attachment with dynamic name.
    Ex: Error_Response_20110802_13.24 where 20110802 is Date and next part represents time stamp.
    File attachment name should change dynamically in Mail receiver Adapter. Thanks
    Regards,
    Sreeramulu Konjeti.

    there is no standard way.
    you will have to write a module to get this in place.
    other ways are;
    XI Mail Adapter: An approach for sending emails with attachment with help of Java mapping - /people/stefan.grube/blog/2007/04/17/xi-mail-adapter-an-approach-for-sending-emails-with-attachment-with-help-of-java-mapping
    Dynamic name in the mail attachment - pseudo "variable substitution" :
    /people/michal.krawczyk2/blog/2006/02/23/xi-dynamic-name-in-the-mail-attachment--pseudo-variable-substitution

  • View full file names of mail attachment titles in MAIL application (Apple)

    I often get many attachments sent to me and when I am looking through emails for some reason all attachments show up as an ICON with a shortened version of the name of the file. It is always just the first 10 or so characters of the title and the last 3, which is usually the (.gif, .pdf, etc...)
    A lot of what I get usually has the similar titles and only seeing the first few characters is not making things easy for me to find exactly what I am looking for.
    Is there a way to view the full file name within the mail and within the application without having to open each file up each time in the APPLE MAIL application?
    Maybe there's a way to show all attachments as a list with a smaller icon?
    Anything that'll let me view the full title of all attachments would help.
    Thanks in advance for any suggestions.
    Message was edited by: KennyMac212

    I agree it is frustrating and literally just sent the wrong attachment to a customer because I was trying to live with the truncated filename system. I did find this nifty app called Mail Iconizer (http://lokiware.info/Mail-Attachments-Iconizer). It's pretty neat as it lets you control how attachments are viewed as well as pdfs and images (based on size). It's a free unlimited trial and $15 if you want to register so it's pretty inexpensive.

  • Mail:send mail:attachment. Is there a simplest way to send a file as an email attachment ? or more correct ?

    <satellite:form  method="post" id="contact-form" enctype="multipart/form-data">
         <input type="file" name="adjunto" />
    </satellite:form>
    FTValList ftListaFichero = new FTValList(1);
    ftListaFichero.setValBLOB(ics.GetVar("adjunto_file"), ics.GetBin("adjunto"));
      <mail:send
           to="<%=to_emailaddress %>"
           from="<%=from_emailaddress%>"
           subject="Subject"
           body="<%=body %>" >
        <mail:attachment value='<%=ftListaFichero.getVal(ics.GetVar("adjunto_file"))%>'/>
      </mail:send>
    http://docs.oracle.com/cd/E29542_01/apirefs.1111/e39371/JSP/mail-attachment.html
    http://docs.oracle.com/cd/E29542_01/apirefs.1111/e39371/JSP/mail-send.html
    Regards,

    Simplest might well be to use javamail API instead of the two tags that Sites provides, e.g. see email - Sending mail attachment using Java - Stack Overflow for a full example.
    Phil

  • Javascript code for setting output file name of emailed form in Livecycle

    I was given a task of creating a new form with livecycle. I have no knowledge of javascripting so I am struggling with one of the things I am trying to get this form to do. The overview of this form is people around my company fill out this form then hit a button to email the completed form to me. I was able to accomplish part of this task by using the following code within an up mouse event script on a button.
    oDoc = event.target;
    oDoc.mailDoc({
    cTo: ********@******.com,
    cSubject: "IB Update Request - Instance" + IBInstance.rawValue,
    This takes the form and emails it to me with the data from the field called "IBinstance" in the subject line which is what I want but the file name attached to the email is garbage. presently is says "newupdateform.pdf - Adobe Acrobat Pro.pdf"
    What I would like is some javascript code that I can take the data from the field called "IBinstance" and use it as the name of the file being sent in. Is there a simple code that i can put in this event to allow me to do this?
    Thank you

    Hi Joerg,
    I have been trying to solve this as well, but gave up. I also could not get the workaround you found to work with EFM files.
    If you do find a solution, please update your message to share?
    Thanks
    Julie

  • File name of emailed report

    When a report is emailed (destype=mail and other des% !!) it always send the attachment as 'report.pdf' (if desformat=pdf).
    IS THERE A WAY TO SET THIS ATTACHMENT FILE NAME?

    Hi Ajay, 
    Try this.  I assumed there would always be a { } in your filename.  I have it checking for them before parsing. 
    Local NumberVar x := Len(Filename) - Len(Replace(Filename, "\", ""));
    Local StringVar myFilename;
    myFilename := SPLIT(Filename, "\") [x + 1];
    If InStr (myFilename, "{") <> 0 Then
         myFilename := myFilename [1 to InStr (myFilename, "{") - 2];
    If InStr (myFilename, "}") <> 0 Then
         myFilename := myFilename [InStr (myFilename, "}") to Length (myFilename)];

Maybe you are looking for

  • Compilation problem in solaris 10

    Hi, Iam using solaris 10 SUNW,UltraAX-i2. Iam trying to compile tripwire binaries tw_ASR_1.3.1_SRC. Iam using gcc 3.3.2, later I installed the libiconv package. on reading the documentation from sunfreeware i modified the file mkheaders.conf putting

  • Bypass Logon screen of the SAP R/3 system where WDA application resides

    Hi, I created an application in WDA. I have another appplication in WDJ. On one of the views of WDJ application, I created a link to URL UI elem and provided WDA application's URL to it as a reference. When I click on the link to URL,  I expect that

  • Dynamic Drop Down Lists

    Hi, As the user types the character in text box, filtered list should be shown below the text box and user can select the item from the list. For e.x. In yahoo mail if type in 'To' text box, filtered list will appear dynamically depending on characte

  • AT NEW & AT END is not triggered

    Hi All, I am having following code where AT NEW & AT END is not get triggered, whenever there is data like following in table. Can any once comment why AT NEW & AT END OF not getting triggered in this case? ITAB-A  ITAB-B Tube                        

  • JMS versus IBM MQSeries

    1. What is the difference between JMS and IBM MQSeries ? 2. If JMS is all about APIs to interact with Message Oriented Middleware (MOM) that IBM MQSeries supports, why not use a simple JAVA program that would import com.ibm. * packages instead of JMS