PdcReport.PrintToFile: Difference between revisions

From External Bemet Wiki
Jump to navigation Jump to search
Created page with "== Declaration == PrintToFile(PathFileName as String) as Boolean == Description == == Notes == This method stores the printpreview of a report as a pdf file. == Code examp..."
 
No edit summary
 
(One intermediate revision by one other user not shown)
Line 6: Line 6:


== Notes ==
== Notes ==
This method stores the printpreview of a report as a pdf file.
It is possible to save reports in different formats, such as PDF and XLS. The format is determined by the file extension used in the supplied path. If the extension cannot be processed it will be defaulted to .pdf.


== Code example ==
== Code example ==

Latest revision as of 08:20, 13 September 2019

Declaration

PrintToFile(PathFileName as String) as Boolean

Description

Notes

It is possible to save reports in different formats, such as PDF and XLS. The format is determined by the file extension used in the supplied path. If the extension cannot be processed it will be defaulted to .pdf.

Code example

This example code opens a report with ID 336 and stores it as "test.pdf" in the folder "C:\temp".

dim objReport

  set objReport = pdc.Reports.Open(336)
  objReport.PrintToFile "C:\temp\test.pdf"

Availability

Available since February 2011 (from version 4.2).