如何每天执行Windows服务在指定的时间 [英] How to execute Windows service at a specified time daily

查看:107
本文介绍了如何每天执行Windows服务在指定的时间的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要安排上,在pre定义的时间每天跑,然后睡觉,一直睡到第二天窗口服务,我该怎么做呢?

I need to schedule windows service on daily basis at pre-defined time to run and then sleep till the next day, How can i do that?

解决方法:

增加了一个定时器超时每30分钟,然后进行验证,如果一天的时间已经达到,如果是,则执行所需的功能,确保,标志着一个标志,一旦其完成的一天。

Added a timer to timeout every 30 minutes and then validate if the time of the day has reached, if yes then perform the desired function, make sure that, mark a flag once its done for the day.

推荐答案

您不知道。您设置计划任务;服务(通常情况下)后台运行的进程。

You don't. You setup a scheduled task; services as (generally) for background running processes.

这篇关于如何每天执行Windows服务在指定的时间的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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