Prints specified pages from a PDF file. Use this tag to perform automated batch print jobs. You can use the cfprint tag to print any PDF document, including those generated by the cfdocument, cfpdf, and cfpdfform tag. Also, you can use this tag to print Report Builder reports exported in PDF format.
<cfprint>
cfprint();
Name | Type | Required | Default | Description |
---|---|---|---|---|
source | string | No | Source document to print. You can specify one of the following: An absolute or relative pathname to a PDF document; for example, c:\work\myPDF.pdf or myPDF.pdf. The default directory is the template directory. A PDF document variable in memory that is generated by the cfdocument tag or the cfpdf tag; for example, “myPDFdoc”. |
|
attributestruct | string | No | ColdFusion structure used to specify additional print instructions. Individually named attributes take precedence over the key-value pairs in the attribute structure. |
|
copies | string | No | Number of copies to print. The value must be greater than or equal to 1. |
|
jobname | string | No | The name of a print job. | |
orientation | string | No | Orientation of the page to be printed. | |
pages | string | No | Pages in the source file to print. Duplicate pages and pages beyond the total count of pages in the document are ignored as long as there is at least one page between 1 and the total number of pages in the document. You can combine individual page numbers and page ranges; for example, 1-3,6,10-20. If you do not specify a value for the pages attribute, ColdFusion prints the entire document. |
|
password | string | No | Specifies either the owner or user password for the PDF source file. If the PDF file is password-protected, you must specify this attribute for the file to print. |
|
papersize | string | No | Paper used for the print job. The value can be any returned by the GetPrinterInfo function. Valid |
|
quality | string | No | Print quality for the print job: * draft * high * normal |
|
color | string | No | Color or monochrome printing | |
coverpage | string | No | Specifies which job start and end sheets, if any, are printed with a job: * none * standard |
|
type | string | No | Specifies the file type of the document being printed. PDF is the only valid value. |
|
printer | string | No | The name of a printer. An example in Windows is \s1001prn02\NTN-2W- HP_BW02. The default is the default printer for the account where the ColdFusion server is running. |
|
sides | string | No | ||
paper | string | No | Paper used for the print job. The value can be any returned by the GetPrinterInfo function. | |
fidelity | boolean | No | NO | Whether to print a job based on the print requirements specified. Valid values are: * yes: if the job cannot be printed exactly as specified in the print requirements, the job is rejected. * no: a reasonable attempt to print the job is acceptable |