Group:  General ยป microsoft.public.officedev
Thread: creating .msg file for MS Outlook

DotNetBag
.NET Development Newsgroups

HTVi
TV Discussion Newsgroups

Our Hot Pick: Rising Antivirus 2006 - Certified by TUV & Checkmark! Get 10% discount by entering this coupon code: ONDISCOUNT10
Rising Antivirus 2006

creating .msg file for MS Outlook
Partheeus 08.02.2006 15:53:27
Hi,

I need to create a ".msg" file, so that some users can click on the message,
and it opens up in MS Outlook. Has anybody successfully done this?
(I#m using the JavaMail APIs)

Using the writeTo method (ie: message.writeTo(fileOut); ), I was able to
create a file. However, when I try and open it in Outlook, it won't open. I
compared my file to a message that I saved using Outlook, and their msg file
has a ton more stuff. It looks like all of the headers are encrypted.

If anybody has done this, and could provide some input, that would be
fantastic!

Thanks.
RE: creating .msg file for MS Outlook
David Ing 08.03.2006 13:55:20
Not from a java API, but the Outlook object model can do it, i.e.
MailItem.SaveAs(msgfilename.msg, olTxt); etc.

Outside that, there are COM libraries that do it too, i.e.
http://www.dimastr.com/redemption/



"Partheeus" wrote:

[Quoted Text]
> Hi,
>
> I need to create a ".msg" file, so that some users can click on the message,
> and it opens up in MS Outlook. Has anybody successfully done this?
> (I#m using the JavaMail APIs)
>
> Using the writeTo method (ie: message.writeTo(fileOut); ), I was able to
> create a file. However, when I try and open it in Outlook, it won't open. I
> compared my file to a message that I saved using Outlook, and their msg file
> has a ton more stuff. It looks like all of the headers are encrypted.
>
> If anybody has done this, and could provide some input, that would be
> fantastic!
>
> Thanks.
Re: creating .msg file for MS Outlook
fergusontra <fergusontra.2etio6[ at ]mail.mcse.ms> 27.09.2006 21:48:32

Actually there is now a way to do this in pure Java. Check out the
library at www.overwrittenstack.com (yes it's mine, but hey it seems to
work).

Right now it supports creating simple MSG Files on any java enabled OS
(could technically be done from linux if needed). You can also dump an
MSG file to a HashMap for reading each of the chunks out separately (I'm
working on making this part a lot easier to use).



--
fergusontra
------------------------------------------------------------------------
http://www.mcse.ms
------------------------------------------------------------------------
View this thread: http://www.mcse.ms/message2121541.html

Home | Search | Terms | Imprint | Contact
Newsgroups Reader - provided by WiredBox.Net