AddAttachment1 Method


Attach a binary stream as attachment to current email with customized file name.

[Syntax]
Visual C++: HRESULT AddAttachment1(BSTR FileName, VARIANT Stream, long* pVal)
Visual Basic: AddAttachment1(FileName As String, Stream As Variant) As Long

Parameters

FileName
File name to be displayed in current email.
Stream
Binary stream of file content, it should be a byte array.

Return Value

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

See Also

AddAttachment Method
AddInline Method
ImportHtml
ImportMailEx

Online Examples

VB6- Send Email with Attachment
VB6 - Send Email with Embedded Images
Delphi - Send Email with Attachment
Delphi - Send Email with Embedded Images
Visual C++ - Send Email with Attachment
Visual C++ - Send Email with Embedded Images