- Код: Выделить всё
Sub GetScreen()
Dim bmpScreenshot As Bitmap
Dim gfxScreenshot As Graphics
bmpScreenshot = New Bitmap(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height, PixelFormat.Format16bppRgb555)
gfxScreenshot = Graphics.FromImage(bmpScreenshot)
gfxScreenshot.CopyFromScreen(Screen.PrimaryScreen.Bounds.X, Screen.PrimaryScreen.Bounds.Y, 0, 0, Screen.PrimaryScreen.Bounds.Size, CopyPixelOperation.SourceCopy)
bmpScreenshot.Save("C:\1.jpg", ImageFormat.Jpeg)
End Sub