I tried the new silent printing options in Spire.Office for WPF. I use the same printers with the same configuration that prints PDF in A6 size.
It prints fine (A6) in the majority of printers and in Adobe (with the option "Automatically resize to fit paper" selected), but it prints as A4 on two printers. I tried page size options, but it only cut the document - scale was still for A4. I found some similar problems on the forum, but the solution -
- Code: Select all
pdf.PageScaling = PdfPrintPageScaling.ActualSize
is not available in this version, I think.
My code:
- Code: Select all
dim By() as byte
Dim doc As New PdfDocument()
doc.LoadFromBytes(By)
Dim H As New Print.PdfPrintSettings With {.PrinterName = PrinterName}
doc.Print(H)
Is there any way to 'Automatically scale to fit paper' in code? Maybe there's some similar option to 'PdfPrintPageScaling.ActualSize'? Since the printers are identical and configured the same way, I am unsure of the origin of the scale problems.
Thank you in advance,
Jacek