Save current email to specified email file.
[Syntax] Visual C++: HRESULT SaveMail(BSTR FileName, long* pVal) Visual Basic: SaveMail(FileName As String) As Long
Parameters
Return Value
Remarks
Example
[VB6, VBA - Save Email as File]
Private Sub SaveEmail()
Dim oSmtp As New EASendMailObjLib.Mail
oSmtp.LicenseCode = "TryIt"
oSmtp.Subject = "test"
oSmtp.BodyText = "this is body"
If oSmtp.SaveMail("c:\test.eml") = 0 Then
MsgBox "Email saved!"
Else
MsgBox "Save email failed!"
MsgBox oSmtp.GetLastErrDescription()
End If
End Sub
See Also