LoadMessage Method


Load email from an EML file (RFC822) to current Mail object.

[Syntax]
Visual C++: HRESULT LoadMessage( BSTR FileName long* pVal )
Visual Basic: LoadMessage( FileName As String ) As Long

Parameters

FileName
The full path of the email file to load.

Return Value

If this method succeeds, the return value is zero; otherwise the return value is non-zero.

Example

[VB6, VBA - Load EML File]  
Dim oSmtp New EASendMailObjLib.Mail
oSmtp.LicenseCode = "TryIt"
'load this email from email.
oSmtp.LoadMessage "c:\my folder\test.eml"

See Also

ImportMailEx Method
SaveMail Method