Converts .EML data (in RFC822 text format) into a file in Outlook .MSG (OLE2) format with 8-bit encoding.
| Exception Type | Condition |
|---|---|
| MailBeeInvalidArgumentException | emlFilename or msgFilename is a null reference (Nothing in Visual Basic). |
| MailBeeException | An error occurred during reading, parsing or saving message data. |
This sample converts .EML file into .MSG file.
[C#] // To use the code below, import these namespaces at the top of your code. using MailBee; using MailBee.Outlook; // The actual code (put it into a method of your class). MsgConvert conv = new MsgConvert(); conv.EmlToMsg(@"C:\test.eml", @"C:\test.msg");
[Visual Basic] ' To use the code below, import these namespaces at the top of your code. Imports MailBee Imports MailBee.Outlook ' The actual code (put it into a method of your class). Dim conv As MsgConvert = New MsgConvert conv.EmlToMsg("C:\test.eml", "C:\test.msg")
MsgConvert Class | MailBee.Outlook Namespace | MsgConvert.EmlToMsg Overload List