I've written an app that grabs parts of the screen from a live feed and saves them as an image. All works fine until the screen sleeps, then the live feed stops working.
If the screen saver is activated i get grabs of the screensaver.
Is there any way of grabbing the screen while the screen is asleep?
If the screen saver is activated i get grabs of the screensaver.
Is there any way of grabbing the screen while the screen is asleep?
Code:
var screen = Screen.PrimaryScreen;
using (var bitmap = new Bitmap(200,160))
using (var graphics = Graphics.FromImage(bitmap))
{
graphics.CopyFromScreen(new Point(10, 10), new Point(0, 0), screen.Bounds.Size);
bitmap.Save("C:\\inetpub\\wwwroot\\Cam1.png", ImageFormat.Png);
}