BCL easyPDF SDK
easyPDF SDK Usermanual
PDF Creator Programming API  |  Download Free Trial  |  Contact Us to Purchase

AttachAttachments Property

Enables to attach the Outlook message's attachments into the output PDF.

Default value: False (disabled).

Type

Boolean

Remarks

When ConvertAttachments and AttachAttachments are enabled (True), the Outlook message's attachments are individually converted to PDF, one at a time. Finally the main Outlook message itself is converted to PDF, and all its attachments are attached into a single output PDF file.

When ConvertAttachments is enabled (True) and AttachAttachments is disabled (False), the Outlook message's attachments are individually converted to PDF, one at a time. Finally the main Outlook message and all its attachments are merged into a single output PDF file.

When ConvertAttachments is disabled (False) and AttachAttachments is enabled (True), the Outlook message's attachments keep their original file formats, and are attached to the PDF converted from main Outlook message.

When ConvertAttachments and AttachAttachments are disabled (False) , the Outlook message's attachments are not attached to the PDF converted from main Outlook message .

Note that in case an error happens while printing any of the attachments, the entire PrintOut function will fail. This means, for example, that if the message contains a RAR attachment, it will likely fail during printing, because PrintJob does not normally know how to print a RAR file. In those cases you need to disable the automatic printing of attachments. Typical attachments that will work fine include DOC, XLS, TXT, JPEG, and anything that PrintJob can normally handle.

Example Usage

Set oPrinter = CreateObject("easyPDF.Printer.8")
Set oPrintJob = oPrinter.OutlookPrintJob
oPrintJob.ConvertAttachments = True
oPrintJob.AttachAttachments = True ' attach Outlook attachments to the PDF
oPrintJob.PrintOut "C:\test\input.msg", "C:\test\output.pdf"