Aspose::Email::EmlLoadOptions Class Reference

Allows to specify additional options when loading MailMessage from Eml format. More...

Inherits Aspose::Email::LoadOptions.

Public Member Functions

bool get_PreserveTnefAttachments () const
 Controls TNEF attachment loading behaviour. By default the value is false. More...
 
void set_PreserveTnefAttachments (bool value)
 Controls TNEF attachment loading behaviour. By default the value is false. More...
 
 EmlLoadOptions ()
 Initializes a new instance of this class that can be used to loading MailMessage from Eml format. More...
 
- Public Member Functions inherited from Aspose::Email::LoadOptions
System::SharedPtr< System::Text::Encoding > get_PreferredTextEncoding () const
 Gets preferred encoding for message. Forcibly sets the preferred encoding for message subject and body. The default value is null. More...
 
void set_PreferredTextEncoding (System::SharedPtr< System::Text::Encoding > value)
 Sets preferred encoding for message. Forcibly sets the preferred encoding for message subject and body. The default value is null. More...
 
System::SharedPtr< Aspose::Email::MessageFormatget_MessageFormat () const
 Represents the mail message format.It can be in eml,msg or mhtml format. The default value is Eml. More...
 
bool get_PreserveEmbeddedMessageFormat () const
 Gets a value indicating whether it is necessary to preserve format of embedded message at loading. By default the value is false. More...
 
void set_PreserveEmbeddedMessageFormat (bool value)
 Sets a value indicating whether it is necessary to preserve format of embedded message at loading. By default the value is false. More...
 
bool get_RemoveSignature () const
 Gets a value indicating whether signature will be removed while loading. More...
 
void set_RemoveSignature (bool value)
 Sets a value indicating whether signature will be removed while loading. More...
 
System::SharedPtr< Aspose::Email::VentureLicense > get_VentureLicense () const
 This is part of the venture licensing pattern. This value will be set by VentureLicenser if the venture passes us a LoadOptions object. More...
 
void set_VentureLicense (System::SharedPtr< Aspose::Email::VentureLicense > value)
 This is part of the venture licensing pattern. This value will be set by VentureLicenser if the venture passes us a LoadOptions object. More...
 
 LoadOptions ()
 

Additional Inherited Members

- Public Attributes inherited from Aspose::Email::LoadOptions
bool IncreaseCredit
 
System::SharedPtr< System::Text::Encoding > preferredTextEncoding
 
System::SharedPtr< Aspose::Email::MessageFormatmessageFormat
 

Detailed Description

Allows to specify additional options when loading MailMessage from Eml format.

The following example shows how to convert EML to MSG.

[C#]

// Initialize EmlLoadOptions
<br>
var emlLoadOptions = new EmlLoadOptions()
{
PreserveEmbeddedMessageFormat = true
};
// Initialize MailMessage with EmlLoadOptions
using (MailMessage message = MailMessage.Load("TestEml.eml", emlLoadOptions))
{
// Convert EML to MSG
message.Save("output.msg", SaveOptions.DefaultMsg);
}

[Visual Basic]

' Initialize EmlLoadOptions
<br>
Dim emlLoadOptions = New EmlLoadOptions() With
{
.PreserveTnefAttachments = True,
.PreserveEmbeddedMessageFormat = True
}
' Initialize MailMessage with EmlLoadOptions
Using message As MailMessage = MailMessage.Load("TestEml.eml", emlLoadOptions)
' Convert EML to MSG
message.Save("output.msg", SaveOptions.DefaultMsg)
End Using

Constructor & Destructor Documentation

◆ EmlLoadOptions()

Aspose::Email::EmlLoadOptions::EmlLoadOptions ( )

Initializes a new instance of this class that can be used to loading MailMessage from Eml format.

Member Function Documentation

◆ get_PreserveTnefAttachments()

bool Aspose::Email::EmlLoadOptions::get_PreserveTnefAttachments ( ) const

Controls TNEF attachment loading behaviour. By default the value is false.

If a message contains a TNEF attachment (winmail.dat) and has the MIME type application/ms-tnef, then this property defines whether files from TNEF will be decoded and extracted. The winmail.dat attachment remains as it is if the property value is true.

◆ set_PreserveTnefAttachments()

void Aspose::Email::EmlLoadOptions::set_PreserveTnefAttachments ( bool  value)

Controls TNEF attachment loading behaviour. By default the value is false.

If a message contains a TNEF attachment (winmail.dat) and has the MIME type application/ms-tnef, then this property defines whether files from TNEF will be decoded and extracted. The winmail.dat attachment remains as it is if the property value is true.

EmlLoadOptions()
Initializes a new instance of this class that can be used to loading MailMessage from Eml format.
@ None
No values are set.