from ironpdf import * # Create a new PDF and print it renderer = ChromePdfRenderer() pdf = renderer.RenderUrlAsPdf("https://www.nuget.org/packages/IronPdf") # Send the PDF to the default printer to print # 300 DPI, no user dialog this time ... many overloads to this method pdf.Print(300) # For advanced printing, we can also use pdf.GetPrintDocument() printer_setting = pdf.GetPrintDocument() printer_setting.PrinterSettings.FromPage = 2 printer_setting.PrinterSettings.ToPage = 4 printer_setting.Print()
纸质打印PDFs