每24小时计算一次 [英] Calculation every 24 hours
问题描述
基本上Evry 24小时我需要从数据库计算总工作时间等
Basicly Evry 24 hours i need to calculate total work time etc from a database
ID | date | tijd | empoyeeID(foreighn)
1 | 2014-03-03 | 14:00:00| 0
2 | same date | 15:00:00| 0
...
(基本注册1 =开始2 =停止3 =开始4 =停止)
因此对于每个日期我需要开始时间和停止时间总工作时间
我应该使用MySql计算或c#
应该挂钩内部窗口时间
我应该使用计时器
你们认为最好的方法是什么?
soz bad england我不是母语为英语的人; )
ps。我已经为单一注册写了evrything(见帖子开头的表)
...
( they are basicly registrations 1 = start 2 = stop 3= start 4 = stop)
so for every date i need the start time and stop time total time worked
should i calculate that with MySql Or c#
should i hook the internal windows time
should i use timers
what dou you guys think is the best aproach
soz bad england I aint a native english speaker ;)
ps. i have written evrything for the single registrations (see table at start of post)
推荐答案
请看我过去的回答:问题窗口服务 [ ^ ]。
-SA
Please see my past answer: Problem a Window Services[^].
—SA
您可以创建一个由Windows调度程序控制的批处理文件。调度程序将在特定时间内触发批处理文件。批处理文件将触发exe,exe将计算您的时间。
谢谢!
You can create a batch file which will be control by windows scheduler. The scheduler will fire the batch file in a certain time. The batch file will fire a exe and the exe will calculate your time.
Thanks!
好吧,使用线程或者转到 Timer 控制.NET。
-KR
Well, use the Thread or maybe go for Timer control of .NET.
-KR
这篇关于每24小时计算一次的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!