Save Outlook message using Java

Hi, I want to save my outlook message as .msg file. I added a new button to the outlook message toolbar, by clicking on that button it will run a java application that will save the outlook message as .msg file.
Can any one help me with some suggestions or code samples in java that will save the current active outlook message.
Thanks in Advance
Siva

>
Hi, I want to save my outlook message as .msg file. I
added a new button to the outlook message toolbar, byIt sounds like you have already "added a new button.." that does this... or is your question how to make the new button actually do stuff?

Similar Messages

  • How to do SAVE AS DRAFT using java mail api

    Hello,
    I want to know how to do SAVE AS DRAFT using Java mail Api.
    thanks

    Hello,
    I want to know how to do SAVE AS DRAFT using Java
    mail Api.
    thanksI don't think you can. That sounds like a feature of a mail client app itself. The Java mail API is for when you're ready to actually send the thing. Saving drafts is storing them somewhere like you would any other data; nothing to do with the mail API.

  • Consuming messages using Java

    Hi,
    I am using BlazeDS running in Tomcat 6.0.16. The Flex client components are written using Flex 3. I have a messaging destination set up and the Flex producers and consumers are working fine. I am able to push messages from the server top the clients using the MessageBroker.routeMessageToService method.
    How can I read/consume messages using Java in the server? I haven't been able to find any documentation or examples on how to do this. Any help and advice is greatly appreciated ... Thanks!
    -- C

    <div class=Section1><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Alex:<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Thank you for your reply. I would prefer not to use JMS since in<br />order to receive messages asynchronously, I would have to use a J2EE message<br />driven bean.  I am trying to implement a listener that can run in Tomcat. <o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'><o:p> </o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Is there a way of doing this without using JMS? Using the<br />message broker I can get a reference to the destination object. And from there<br />I presume it is a matter of registering a callback handler or such &#8230; but<br />I couldn&#8217;t find anything similar in the javadocs.<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Cheers,<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'><o:p> </o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'>Chamara<o:p></o:p></span></p><br /><br /><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";<br />color:#1F497D'><o:p> </o:p></span></p><br /><br /><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><br /><br /><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span<br />style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Alex Glosband<br />[mailto:[email protected]] <br><br /><b>Sent:</b> Thursday, March 13, 2008 9:04 AM<br><br /><b>To:</b> [email protected]<br><br /><b>Subject:</b> Re: Consuming messages using Java<o:p></o:p></span></p><br /><br /></div><br /><br /><p class=MsoNormal><o:p> </o:p></p><br /><br /><p class=MsoNormal style='margin-bottom:12.0pt'>A new message was posted by<br />Alex Glosband in <br><br /><br><br /><b>General Discussion</b> --<br><br />  Consuming messages using Java<br><br /><br><br />The easiest way to do this is to use the JMS messaging adapter in BlazeDS. This<br />adapter lets your Flex clients publish messages to and receive messages from<br />JMS destinations. You can also have Java JMS clients that send messages to and<br />receive messages from these same destinations. <br><br /><br><br />Take a look at the &quot;Configuring the JMS adapter&quot; section of BlazeDs<br />dev guide for more information about this. <br><br /><br><br /><a<br />href="http://livedocs.adobe.com/blazeds/1/blazeds_devguide/help.html?content=messaging_ config_3.html#256378">http://livedocs.adobe.com/blazeds/1/blazeds_devguide/help.html?conte nt=messaging_config_3.html#256378</a><br /><br><br /><br><br />-Alex <o:p></o:p></p><br /><br /><div class=MsoNormal><br /><br /><hr size=2 width=200 style='width:150.0pt' align=left><br /><br /></div><br /><br /><p class=MsoNormal style='margin-bottom:12.0pt'>View/reply at <a<br />href="http://www.adobeforums.com/webx?13@@.59b4a54c/0">Consuming messages using<br />Java</a><br><br />Replies by email are OK.<br><br />Use the <a<br />href="http://www.adobeforums.com/webx?280@@.59b4a54c!folder=.3c061a83">unsubscribe</a>< br />form to cancel your email subscription.<o:p></o:p></p><br /><br /></div>

  • Getting outlook contacts using java

    hi every body,
    is anybody know how to get the OutLook contacts using java.

    look at IBM's free bridge2java (Google for it)
    this has examples or how to extract address book entries ect. from Outlook as wekk as interacting with other COM-based interfaes.

  • Complete code to send an attachment with a text message using java mailapi

    complete code to send an attachment with a text message using java mailapi
    code should be free from error

    http://java.sun.com/products/javamail/FAQ.html#examples
    Was this code too hard to find?
    Was the FAQ too hard to find?

  • How to show error message using java.awt?

    How to show error message using java.awt?
    Which is the class corresponding to the JOptionPane?
    Or I need to use Frame ?

    No, JOptionPane is swing!
    You would have to create your own frame, put your message in it, then show it.

  • How to read outlook mail using java

    Hi,
    I am new to javamail ,
    I want to read outlook mail using java
    thanks
    Edited by: My_Problems on Jun 20, 2008 11:13 AM

    Hi!
    See Java Api Msgparser in GNU General Public License...
    A parser for .msg Files in Java :
    [http://auxilii.com/msgparser/|http://auxilii.com/msgparser/]
    Use POI... Apache POI - Java API To Access Microsoft Format Files...
    regards,

  • SAP BO Report Scheduling and Save as report using Java SDK

    Hi All,
    We have a java product which is integrated with SAP BO using Java SDK and we have certain java screen through which we select report prompt values and webi report gets run.
    Now we want to give a functionality to save report to BO repository.
    When user select certain check box from java screen a separate copy of the webi report should get saved under default folder on BO repository.
    Also, we want user to choose the scheduling option from java screen only (and not the one which we use from BI Launchpad) due to certain access restriction. User does not have access to BI Launchpad. Only he can run report by selecting values through Java screen.
    If i need to create a separate screen for scheduling as well as saving webi report then also i am ok with it.
    P.S. i guess we need to work on Java SDK level. But could somebody please help me with the right direction?
    Let me know in case requirement is not clear.

    Hi Ketan,
    As you are on version BI 4.0 SP5 and would be migrating to BI 4.1, the best SDKs to use would be the Restful Webservices SDKs.
    You have the options to schedule a webi report with prompts as well as the save feature which you require.
    Please refer to the webi restful guides avialble at
    For BI 4.0 SP5
    http://help.sap.com/businessobject/product_guides/boexir4/en/xi4sp5_webi_restful_ws_en.pdf
    For BI 4.1 SP4
    http://help.sap.com/saphelpiis_sbo41sp4wi-sdk/frameset.htm
    Refer to the below blog to understand the Restfull Webservices SDKs.
    http://scn.sap.com/community/restful-sdk/blog/2013/09/07/scripting-web-intelligence-the-restful-raylight-web-services--learing-it
    More blogs on Rest are available at
    http://scn.sap.com/community/restful-sdk/content#filterID=contentstatus%5Bpublished%5D~objecttype~objecttype%5Bblogpost%5D
    You can find the samples from the below link
    http://scn.sap.com/community/restful-sdk/content#filterID=contentstatus%5Bpublished%5D~objecttype~objecttype%5Bdocument%5D
    You would need to refer to the community below in case you have concerns about Rest SDKs.
    http://scn.sap.com/community/restful-sdk
    Thanks,
    Prithvi

  • Problem in sending messages using java mail api

    Hi All,
    I have a problem in sending messages via java mail api.
    MimeMessage message = new MimeMessage(session);
    String bodyContent = "ñSunJava";
    message.setText (bodyContent,"utf-8");using the above code its not possible for me to send the attachment. if i am using the below code means special characters like ñ gets removed or changed into some other characters.
    MimeBodyPart messagePart = new MimeBodyPart();
                messagePart.setText(bodyText);
                // Set the email attachment file
                MimeBodyPart attachmentPart = new MimeBodyPart();
                FileDataSource fileDataSource = new FileDataSource("C:/sunjava.txt") {
                    public String getContentType() {
                        return "application/octet-stream";
                attachmentPart.setDataHandler(new DataHandler(fileDataSource));
                attachmentPart.setFileName(filename);
                Multipart multipart = new MimeMultipart();
                multipart.addBodyPart(messagePart);
                multipart.addBodyPart(attachmentPart);
                message.setContent(multipart);
                Transport.send(message);is there any way to send the file attachment with the body message without using MultiPart java class.

    Taken pretty much straight out of the Javamail examples the following works for me (mail read using Thunderbird)        // Define message
            Message message = new MimeMessage(session);
            message.setFrom(new InternetAddress(from));
            // Set the 'to' address
            for (int i = 0; i < to.length; i++)
                message.addRecipient(Message.RecipientType.TO, new InternetAddress(to));
    // Set the 'cc' address
    for (int i = 0; i < cc.length; i++)
    message.addRecipient(Message.RecipientType.CC, new InternetAddress(cc[i]));
    // Set the 'bcc' address
    for (int i = 0; i < bcc.length; i++)
    message.addRecipient(Message.RecipientType.BCC, new InternetAddress(bcc[i]));
    message.setSubject("JavaMail With Attachment");
    // Create the message part
    BodyPart messageBodyPart = new MimeBodyPart();
    // Fill the message
    messageBodyPart.setText("Here's the file ñSunJava");
    // Create a Multipart
    Multipart multipart = new MimeMultipart();
    // Add part one
    multipart.addBodyPart(messageBodyPart);
    // Part two is attachment
    for (int count = 0; count < 5; count++)
    String filename = "hello" + count + ".txt";
    String fileContent = " ñSunJava - Now is the time for all good men to come to the aid of the party " + count + " \n";
    // Create another body part
    BodyPart attachementBodyPart = new MimeBodyPart();
    // Get the attachment
    DataSource source = new StringDataSource(fileContent, filename);
    // Set the data handler to this attachment
    attachementBodyPart.setDataHandler(new DataHandler(source));
    // Set the filename
    attachementBodyPart.setFileName(filename);
    // Add this part
    multipart.addBodyPart(attachementBodyPart);
    // Put parts in message
    message.setContent(multipart);
    // Send the message
    Transport.send(message);                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Print messages using Java or Jython

    Hi,
    In my ODI procedure I would like to print out some results to make it easier to check the results.
    Is there a way to print out messages in a step using java or jython?
    I tried out to print to stdout - that did not work...
    Thanks,
    Helmut

    Hi H,
    Sure.
    Below is the sample code snippet,
    import os
    ftrg = open('c:/temp/listdir.txt', 'w')
    try:
    __mydir = 'c:/odi'
    __mylist = os.listdir(mydir)
    __mylist.sort()
    __for dirOrFile in mylist:
    ____if os.path.isdir(mydir + os.sep + dirOrFile):
    ______print >> ftrg, 'DIRECTORY: %s' % dirOrFile
    ____else:
    ______print >> ftrg, 'FILE: %s' % dirOrFile
    finally:
    __ftrg.close()
    The above code will print the list of directories in a specified path to a file listdir.txt.
    P.S: If you want to try the code please replace __ with tab. Also, you can have a look at oracledi_jython_reference.pdf for more info.
    Thanks,
    G

  • Right way to reinstall OS 9.2.1-9.2.2 update & SAVE OUTLOOK MESSAGES etc

    I have now an original OS 9.2.1 CD to make the reistallation of the system on a Powerbook G3 (Wallsteet 266 Mhz, HD 4Gb) already equipped with 9.2.2.
    - Once having installed the 9.2.1, it's enough to download the 9.2.2 update I see in 'Apple Support', install it, and that is all?
    - In Mac HD>Applications>Apple Extra on my Powerbook there is a folder 'Mac OS 9.2.2 updating', that contains several elements among which 'Update to Mac OS 9.2.2': I opened it and it seems to be what needs to install 9.2.2. Could have it been left there by the people who previously installed it on the computer? Can I use it directly to reinstall 9.2.2?
    - Of course I will backup all my files, but what to do exactly to save my Outlook mail messages (they are thousands) and my Explorer favourites, and what to do exactly to have them available again, once having reinstalled the system?
    - what to do if I want also to import all messages, addresses, accounts, etc, from the Wallstreet to another Powerbook, either in another Outlook or in Entourage or in Mail?
    Thank you for any help.

    Assuming you mean Outlook Express, Entourage and later OE versions store their messages, etc, in the Microsoft User Data at the top level of your Documents folder.
    Simply copying that folder, making your new installations, copying MSUD back then Restarting will feed the old data to new configuration... (Please remember, MSUD from the new configuration must be Trashed before the old data can be copied back)
    In Explorer use File>Export Favorites to put them somewhere safe before the update, then pull them back with File>Import Favorites…
    When you want also to import all messages, addresses, accounts, etc, to another Powerbook that depends whether you're simply trying to replace what's on the target Mac with the data from the source Mac, or merge two sets of data.
    To simply replace what's on the target Mac with the data from the source Mac, as above copy the entire MSUD…
    To fully merge two Outlook or Entourage data sets is certainly not possible if the source data contains mugshots or user-defined Categories. Mail and iCal might fully Import OE or Entourage messages and Calendar events but I don't believe Address Book will swallow all their contact details, and you may also be thwarted by other things I don't know about.
    Beside the formal Export-Import method, you can drag and drop Entourage messages, complete mail folders, calendar events and contacts into Finder folders.
    Messages and mail folders can then be dragged into any other open Entourage.
    Calendar events become .ICS files and contacts become .VCF cards which will automatically join Entourage on a new host once they're double clicked open…

  • Error while trying to save a report using Java SDK for CR server 2011

    I use the java sdk to update the report database jndi alias and then save the report. While saving the report, the utility throws the following exception. It only happens to 3 reports out of more than 70 reports. What could be the problem with report that is causing this problem ?
    Thanks.
    com.crystaldecisions.sdk.occa.report.lib.ReportSDKServerException: Failed to read data from report file C:\Program Files (x86)\SAP BusinessObjects\SAP BusinessObjects Enterprise XI 4.0\Data\CrystalRep
    ortsRasServer\temp\{56586260-E771-4C63-BF8B-F3CF14BB508A}.rpt. Reason: Repository object could not be found.---- Error code:-2147467259 [CRSDK00000000] Error code name:failed
            at com.crystaldecisions.sdk.occa.report.lib.ReportSDKServerException.throwReportSDKServerException(ReportSDKServerException.java:109)
            at com.crystaldecisions.proxy.remoteagent.ExceptionHelper.throwResultInfoException(ExceptionHelper.java:192)
            at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.sendSyncRequest(ReportClientDocument.java:803)
            at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.doSave(ReportClientDocument.java:820)
            at com.crystaldecisions.sdk.occa.report.application.ReportClientDocument.save(ReportClientDocument.java:2245)

    The error points to the report using a repository object that it cannot be found.  What happens if you try and update the reports using the Crystal Report Designer instead of the SDK?

  • Jacob - save outlook message as .msg file

    Hi,
    I need to save an outlook mail item as a .msg file using Jacob.
    In C# I would use the syntax
    mail.SaveAs(savePathAndName, Outlook.OlSaveAsType.olMSG) where 'mail' is an outlook mailitem, the first parameter is a string and the second parameter is a type.
    In Jacob I've tried various combinations of
    Variant saveResult = Dispatch.call(mailItem, "SaveAs", "Microsoft.Office.Interop.Outlook.OlSaveAsType.olMSG");
    with no success
    Any ideas?
    tvm
    RCF

    Variant saveResult = Dispatch.call(mailItem, "SaveAs", directory + "newEmailName.msg");
    thanks you, i found it because of you :)

  • How can I open/save .xlsx file using java

    Hi
    I have a jsp whose contenttype of response is application/vnd.ms-excel.
    When I am saving the file as .xlsx and opening from disk it displays error message.
    How can I save and/or open the file as .xlsx?
    Any advice will be appreciated.
    Thanks
    Rohini Kumar J

    sunshine_vennela wrote:
    I have a jsp whose contenttype of response is application/vnd.ms-excel.That's not the way to create excel files. You're just creating a plain vanilla HTML file and fooling the browser with a wrong content type.
    Checkout the Apache POI XSSF API or the OpenXML4J API's to create xlsx files and use a servlet to write it to the outputstream.

  • How do I Save Outlook Attachments using Powershell?

    I have seen a few examples of this for vbScript, but none for powershell.
    Here is a script I found to open Outlook and pick a folder:
    function Release-Ref ($ref) {
    ([System.Runtime.InteropServices.Marshal]::ReleaseComObject(
    [System.__ComObject]$ref) -gt 0)
    [System.GC]::Collect()
    [System.GC]::WaitForPendingFinalizers()
    $o = New-Object -comobject outlook.application
    $n = $o.GetNamespace("MAPI")
    $f = $n.PickFolder()
    Write-Host $f.name
    $a = Release-Ref($f)
    $a = Release-Ref($n)
    $a = Release-Ref($o)
    Now I want to save the Excel attachments in the folder I pick.
    Better yet, I want to Open the attachements in Excel and copy the contents to a master spreadsheet.
    Again, I found a vbScript in "Hey Scripting Guy" BUT, The format is so mangled, I can not read the script.
    Anyone else have that problem? The scripts come out as one long line of text.

    because you didn�??t filter out emails without attachments so the first email it comes to in that box doesn�??t have one, and the value is null, and fails.
    in that script, where $a = $f.items, that�??s just assigning all emails because $f is the folder and .items is all items in that folder.
    so that item may not have an attachment, hence the null error
    I think you can do
    foreach ($item
    in
    $f.items)
    $sender
    =
    $item.SenderName
    foreach($attach
    in
    $item.Attachments)
    if($attach.filename.contains("xlsx"))
    write-host
    "$sender sent $($attach.filename)"
    I did this on my inbox and for the most part it worked. I would some times get the error you got and I cant figure out why. In testing I found that it identified that it had attachments when it didn�??t.

Maybe you are looking for

  • Is there a way to create an if statement in dreamweaver?

    I am currently building a website that sells industrial seating. There is a seat called SP006 that appears both in section, "small suspension seats" and "construction". So far I have been resaving the same page twice but renaming it "sp006_constructi

  • Tecra M5 freezes at splash screen on startup (post Safeguard Easy Install)

    Since installing Safeguard Easy disk encryption, my M5 freezes at the initial Toshiba splash screen. Pressing Ctrl - Alt - Delete gets passed this and onto the Safeguard password screen. It seems there is a BIOS patch for the Satellite Pro series but

  • Tenda W311U not working after recent update

    I just updated my pogo with pacman -Syu and now I can not load the rt2800usb module for my W311U wireless card . Any ideas on whats wrong?

  • An unexpected error

    I'm importing a 2-record file to "opportunities" as a test, and cant get it to go in. Both records throw the same log error: <em>An unexpected error occurred during the import of the following row: 'Payment ID: 31384'</em> I've tried removing that pa

  • How to Colorize your layers

    Here is a simple example in how to Colorize your layers in two different ways. First, duplicate the layer you would like to adjust. To duplicate the layer, select the layer in the Layer palette. Then choose Layer > Duplicate Layer. You can click the