Windows Services在Windows 7中一段时间​​后会自动暂停 [英] Windows Services pause automatically after sometime in windows 7

查看:196
本文介绍了Windows Services在Windows 7中一段时间​​后会自动暂停的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在C#.NET中创建了Windows服务.
当我将其安装在窗口7中后,它便开始工作了,该服务内部有许多计时器.
剩下的时间(一个小时或半小时)之后,它将进入用户登录页面,然后在登录后,当我们登录到用户PC时,它将从该位置再次启动计时器.
但是它不会重新启动.因为我在启动服务时记录了一些值.
我已从11.00开始服务,然后它将转到位于13.00的用户登录页面,然后在登录后将不会记录该值.这意味着它将暂停一段时间.

I have created windows service in C#.NET.
When I have installed this in window 7 then it''s working there are number of timers inside the service.
After sometime left(an hour or half hour) it will going to user login page then after login it will start the timer again from that position when we logged to the user PC.
But it will not restarted. Because I have logged some value at time starting the service.
I have started service at 11.00 then it will going to the user login page at 13.00 then it will not logged the value after logging. It means, it will paused for sometime.
How to avoid this windows service going to the paused mode?

推荐答案

如果您不使用System.Threading.Timer,请尝试使用它.
If you are not using a System.Threading.Timer then try that instead.


这篇关于Windows Services在Windows 7中一段时间​​后会自动暂停的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆