|
|
|
date: Tue, 18 Mar 2008 09:44:03 -0700,
group: microsoft.public.exchange.development
back
Re: How save message from Exchange 2003 in msg format
MSG format is Extended MAPI specific. You can use Extended MAPI (C++/Delphi
only, see http://support.microsoft.com/kb/171907) to create a blank MSG file
and import the EML file (use IConverterSEssion if you have Outlook 2002 or
higher installed or, in case of Exchange, you will need to create your own
parser).
<plug>
Or you can use Redemption, which does the above and works both with the
Outlook version of MAPI and the one installed by Exchange:
RDOSession RDOSession1 = new RDOSession();
RDOMail Msg;
Msg = RDOSession1.GetMessageFromMsgFile(@"c:\temp\test.msg", true)
Msg.Import(@"c:\temp\test.eml", rdoSaveAsType.olRFC822);
Msg.Save();
</plug>
Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool
"Ilya" wrote in message
news:5D9363CA-309F-4EAB-9E45-3B228715BB24@microsoft.com...
> Hi
> I'm using Exchange 2003 and cdoex.dll version 6.5.6944.0 (from Exchange
> sever directory)
> I execute code like this:
> Code Snippet
>
> MessageClass msg = new MessageClass();
> msg.DataSource.Open(...);
> ADODB.Stream stream = msg.IBordyPart_GetSream();
> stream.SaveToFile("C:\myMes.msg",//someoptions);
>
>
> All right this is work, but file myMes.msg save in .eml format, Can I save
> message to file or get Stream in msg format immediatly ?? Or convert to
> msg
> programmaticly??
>
> Thanks!
date: Tue, 18 Mar 2008 12:06:48 -0700
author: Dmitry Streblechenko
|
|