从网络打印机打印 PDF.

Curtis Chau
Curtis Chau
Updated: 2026年4月22日

如何使用 IronPDF 从网络打印机打印?

IronPDF 支持 C# 可用的所有打印选项。

发送到默认打印机:

使用Print方法将PDF发送到默认打印机。

IronPdf.PdfDocument.Print(System.Boolean)

// C# example of sending a PDF document to the default printer
using IronPdf;

var pdf = PdfDocument.FromFile("example.pdf");

// Sends the document to the default printer
pdf.Print();

发送到指定名称的打印机:

使用重载的Print方法通过名称指定打印机。

IronPdf.PdfDocument.Print(System.String, System.Boolean)

// C# example of sending a PDF document to a specific printer by name
using IronPdf;

var pdf = PdfDocument.FromFile("example.pdf");
string printerName = "MyNetworkPrinter";

// Sends the document to the specified printer
pdf.Print(printerName);

发现打印机:

要将文档发送到特定的打印机,请确保该打印机已被"发现"。

对于 AirPrint:

如果使用 AirPrint,请尝试以下建议:

您也可以尝试: PdfDocument.Print重载,会显示打印预览窗口,并且如果可用,将允许选择AirPrint。

Curtis Chau 拥有卡尔顿大学的计算机科学学士学位,专注于前端开发,精通 Node.js、TypeScript、JavaScript 和 React。他热衷于打造直观且美观的用户界面,喜欢使用现代框架并创建结构良好、视觉吸引力强的手册。

阅读更多

准备开始了吗?

Nuget Downloads 21,916,531版本:2026.11刚刚发布