AddFile
PowerScript function
Description
Specifies a file to add as attachment of a PDF document.
Applies to
PDFAttachment object in Objects and Controls
Syntax
|
1 |
long AddFile(string localFilePath) |
|
Argument |
Description |
|---|---|
|
localFilePath |
The path and file name of the local file to add. |
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.
|
1 2 3 4 5 |
lpdf_doc = create PDFdocument lpdf_attach = create PDFattachment lpdf_attach.addfile ( "D:imageimage.png") lpdf_doc.attachment = lpdf_attach |
See also
Document get from Powerbuilder help
Thank you for watching.
Subscribe
Login
0 Comments
Oldest