Как я могу напечатать Qrcode в vb.net?
Я сделал код, который генерирует QR-код. И теперь я пытаюсь напечатать его в термобумаге. Но как я могу напечатать конкретный размер бумаги? Спасибо
Private Sub GraphicPrint(ByVal sender As Object, ByVal e As PrintPageEventArgs)
Dim x As Integer = 60
Dim y As Integer = 60
Dim width As Integer = 100
Dim height As Integer = 50
' e.Graphics.DrawImage(Image.FromFile(GraphicLocation.Text), x, y, width, height, e.Graphics.VisibleClipBounds)
e.Graphics.DrawImage(Image.FromFile(GraphicLocation.Text), x, y, width, height)
e.HasMorePages = False
End Sub
Private Sub BeginGraphicPrint_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles BeginGraphicPrint.Click
Try
AddHandler PrintGraphicControl.PrintPage, AddressOf Me.GraphicPrint
PrintGraphicControl.Print()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub