Description
Specifies a folder to add the files in it as attachments of a PDF document.
Applies to
Syntax
long AddFolder(string localFolderPath, boolean isRecurse)
Argument |
Description |
---|---|
localFolderPath |
The path to the local folder. |
isRecurse | Whether to recursively get the files in the sub folders of the specified local folder. |
Return value
Long. Returns 1 if it succeeds and -1 if an error occurs. For the full list of error codes, see Error Codes.
Usage
Call the function to add the files in the specified folder as attachments of the PDF document. The isRecursive argument controls whether to also add the files in the sub folders.
Examples
This example add all the files, including the files in the sub folders, in the "D:\image" folder as attachments to the newly-created PDF document.
lpdf_doc = create PDFdocument lpdf_attach = create PDFattachment lpdf_attach.addfolder ( "D:\image",true) lpdf_doc.attachment = lpdf_attach
See also