I am having an issue with printing my screen to a printer. The process works properly up to the point to where it cuts off the image. My screen is set to 1680 by 1050 and it seems like I am only getting 1024 by 768 (or something to that effect). Below is the code i am using...
Dim memoryImage As Bitmap
Private Sub printDocument1_PrintPage(ByVal sender As System.Object, ByVal e As System.Drawing.Printing.PrintPageEventArgs) Handles PrintDocument1.PrintPage
e.Graphics.DrawImage(memoryImage, frmMain.Location.X, frmMain.Location.Y)
End Sub
Private Sub PrintScreen()
Dim myGraphics As Graphics = frmMain.CreateGraphics()
Dim s As Size = frmMain.Size
memoryImage = New Bitmap(s.Width, s.Height, myGraphics)
Dim memoryGraphics As Graphics = Graphics.FromImage(memoryImage)
memoryGraphics.CopyFromScreen(frmMain.Location.X, frmMain.Location.Y, 0, 0, s)
End Sub
Thanks for your help, in advance.
Dim memoryImage As Bitmap
Private Sub printDocument1_PrintPage(ByVal sender As System.Object, ByVal e As System.Drawing.Printing.PrintPageEventArgs) Handles PrintDocument1.PrintPage
e.Graphics.DrawImage(memoryImage, frmMain.Location.X, frmMain.Location.Y)
End Sub
Private Sub PrintScreen()
Dim myGraphics As Graphics = frmMain.CreateGraphics()
Dim s As Size = frmMain.Size
memoryImage = New Bitmap(s.Width, s.Height, myGraphics)
Dim memoryGraphics As Graphics = Graphics.FromImage(memoryImage)
memoryGraphics.CopyFromScreen(frmMain.Location.X, frmMain.Location.Y, 0, 0, s)
End Sub
Thanks for your help, in advance.