PrintAsPDF
PowerScript function
Description
Prints the current web page as a PDF file.
Applies to
WebBrowser controls
Syntax
|
1 |
controlname.PrintAsPDF ( string PdfFile ) |
|
Argument |
Description |
|---|---|
|
controlname |
The name of the WebBrowser control. |
|
PdfFile |
The file path and file name of the PDF file to be |
Return value
Integer.
-
1 — Success.
-
-1 — General error.
-
-2 — Failed to get the browser instance.
-
-3 — Invalid file path or file name.
-
-4 — The folder where the PDF file will be saved does not
exist.
Examples
This example prints the current web page as printaspdf.pdf and saves
it under the current directory:
|
1 2 3 4 |
Integer li_rtn String ls_pdfpath Ls_pdfpath = getcurrentdirectory() + "printaspdf.pdf" Li_rtn = wb_1.PrintAsPDF(ls_pdfpath) |
See also
Document get from Powerbuilder help
Thank you for watching.
Subscribe
Login
0 Comments
Oldest