Hi,
I am using the following code to take a Snapshot of a panel that is 200 X 110.
I then print the image to a printer.
This works great.
However, the printed image is large and I must reduce the size of the image printed to fit onto the label.
Is there a function that will allow me to Scale or Resize the image prior to printing?
I am using the following code to take a Snapshot of a panel that is 200 X 110.
I then print the image to a printer.
B4X:
MainForm = Form1
MainForm.RootPane.LoadLayout("2") 'Load the layout file.
MainForm.Show
Dim m As Image = MainForm.RootPane.Snapshot
Dim cv As Canvas
cv.Initialize("")
cv.DrawImage(m,0,0,200,100)
Dim P As Printer = Printer_Static.GetDefaultPrinter
Dim PJ As PrinterJob = PrinterJob_Static.CreatePrinterJob2(P)
PJ.PrintPage(cv)
PJ.PrintPage(pnlQR)
PJ.EndJob
However, the printed image is large and I must reduce the size of the image printed to fit onto the label.
Is there a function that will allow me to Scale or Resize the image prior to printing?