Imprimer des PDF à partir d'imprimantes de réseau
Comment utiliser IronPDF pour imprimer à partir d'une imprimante réseau ?
IronPDF prend en charge toutes les options d'impression disponibles pour C#.
Envoyer à une imprimante par défaut :
Utilisez la méthode Print pour envoyer le PDF à l'imprimante par défaut.
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(showPreview: false); // set `showPreview` to true to see a preview before printing
// 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(showPreview: false); // set `showPreview` to true to see a preview before printing
' C# example of sending a PDF document to the default printer
Imports IronPdf
Private pdf = PdfDocument.FromFile("example.pdf")
' Sends the document to the default printer
pdf.Print(showPreview:= False) ' set `showPreview` to true to see a preview before printing
Envoyer à une imprimante nommée :
Utilisez la méthode surchargée Print pour spécifier l'imprimante par son nom.
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, showPreview: false);
// 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, showPreview: false);
' C# example of sending a PDF document to a specific printer by name
Imports IronPdf
Private pdf = PdfDocument.FromFile("example.pdf")
Private printerName As String = "MyNetworkPrinter"
' Sends the document to the specified printer
pdf.Print(printerName, showPreview:= False)
Découvrir les imprimantes :
Pour envoyer le document à une imprimante spécifique, assurez-vous que l'imprimante est 'découverte'.
Pour AirPrint :
Essayez les suggestions suivantes si vous utilisez AirPrint :
- AirPrint : Imprimer un fichier PDF directement sur l'imprimante
- Comment simuler une imprimante AirPrint
Vous pouvez également essayer :
PdfDocument.GetPrintDocument() ou PdfDocument.Print surcharges, qui affichent la fenêtre d'aperçu avant impression et, si disponible, permettront de sélectionner AirPrint.

