Print Settings
Instantiate the PrintSettings class and configure it according to your requirements. Finally, pass the PrintSettings object to one of the print methods. Explore all the available print settings below:
- DefaultSettings: Initializes a new instance of the IronPrint.PrintSettings class with default values.
- PaperSize: Sets the paper size used by the printer.
- PaperOrientation: Specifies the paper orientation (e.g., Portrait or Landscape).
- Dpi: Represents the intended print resolution in dots per inch. Remarks: The actual DPI used for printing might be limited by the capabilities of the printer.
- NumberOfCopies: Indicates the number of identical copies to be generated when printing a document. Remarks: In certain platforms, limitations may exist that prevent the accurate reproduction of multiple copies. In such cases, the specified value of IronPrint.PrintSettings.NumberOfCopies might be ignored, resulting in only one copy being printed.
- PrinterName: Specifies the name of the printer to use for printing. Remarks: If you choose the printer in a PrintDialog, this setting will be ignored. To obtain the available printer names, you can use IronPrint.Printer.GetPrinterNames or IronPrint.Printer.GetPrinterNamesAsync to fetch the printer name list.
- PaperMargins: Sets the margins to use for printing in millimeters.
- Grayscale: Indicates whether to print in grayscale.
- Flatten: Flatten the PDF before printing, which is useful for displaying form field values and images. The default value is false, indicating that the PDF will be flattened before printing.
- Tray: Printer tray used for the printing job. This allows users to specify a particular tray from which paper should be fed into the printer. If you choose the tray in a PrintDialog, this setting will be ignored. To obtain the available tray, you can use IronPrint.Printer.GetPrinterTrays(System.String) or IronPrint.Printer.GetPrinterTraysAsync(System.String). The default value is null, indicating the use of the default tray provided by the printer. This tray selection property is available only in Windows.