Hello,
Thanks for your prompt feedback. If there is any other question, welcome to contact us.
Best regards,
Simon
E-iceblue support team
PdfDocument doc = new PdfDocument();
doc.LoadFromFile(@"LOCATOR_0000764796.pdf");
PaperSize paperSize = new PaperSize();
paperSize.Width = 215;//inch*100
paperSize.Height = 125;//inch*100
paperSize.RawKind = (int)PaperKind.Custom;
doc.PrintSettings.PaperSize = paperSize;
doc.PrintSettings.SelectSinglePageLayout(PdfSinglePageScalingMode.CustomScale, false, 100f);
doc.Print(); //set an higher quality(the second parameter)
page.Canvas.DrawImage(image,100, 30, 30, fitWidth, fitHeight);
// To convert HTML to PDF using Spire Pdf
Spire.Pdf.PdfDocument pdf = new Spire.Pdf.PdfDocument();
PdfHtmlLayoutFormat htmlLayoutFormat = new PdfHtmlLayoutFormat();
htmlLayoutFormat.IsWaiting = false;
PdfPageSettings settings = new PdfPageSettings();
settings.Orientation = PdfPageOrientation.Portrait;
pdf.PageScaling = PdfPrintPageScaling.ActualSize;
pdf.PageSettings = settings;
string htmlCode = templateInfo;
Thread thread = new Thread(() => { pdf.LoadFromHTML(htmlCode, true, settings, htmlLayoutFormat); });
thread.SetApartmentState(ApartmentState.STA);
thread.Start();
thread.Join();
pdf.SaveToFile(filePath + fileName + ".pdf"); PdfDocument doc = new PdfDocument();
doc.LoadFromFile(input);
doc.PrintSettings.PrinterName = "printer Name";
doc.Print(); MemoryStream ms = new MemoryStream();
PdfDocument doc = new PdfDocument();
doc.LoadFromFile(input);
doc.SaveToStream(ms, FileFormat.XPS);
ms.Position = 0;
XpsPrint.XpsPrintHelper.Print(ms,printerName,"My printing job", true);