Tag: 屏幕捕获

Windows服务屏幕捕获返回黑屏

我正在尝试创建Windows服务应用程序来捕获屏幕。 以前我有启动服务的问题 。 无论如何我能够解决它,现在我有另一个问题。 现在图像正在保存,但它保存为黑屏。 为此,在SOF中提出了很多问题,但我无法解决我的问题。 这是我到目前为止所尝试的: public partial class ScreenCaptureService : ServiceBase { private static Bitmap bmpScreenshot; //private static Graphics gfxScreenshot; System.Timers.Timer timer = new System.Timers.Timer(); public ScreenCaptureService() { InitializeComponent(); } protected override void OnStart(string[] args) { TraceService(); timer.Elapsed += new ElapsedEventHandler(OnElapsedTime); timer.Interval = 60000; timer.Enabled = true; } protected override void OnStop() { […]