473,406 Members | 2,293 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

how to monitor the system clock for changes

i'm working on a windows service that needs to check the system's clock
every minute and see if there are any jobs in my database taht are scheduled
to run at that time:

sSql = "select * from tblJobs where runTime = " + dtTheCurrentSystemTime

are there any classes designed to allow me to monitor changes to the system
clock?

tks
Jul 19 '07 #1
2 3160

Check the following link. You might have to do some indenting though, as
there seems to be a bit of a problem with the source code being displayed.

http://msdn2.microsoft.com/en-us/lib...DownFilterText
Adrian.
--
[Please mark my answer if it was helpful to you]


"Dica" wrote:
i'm working on a windows service that needs to check the system's clock
every minute and see if there are any jobs in my database taht are scheduled
to run at that time:

sSql = "select * from tblJobs where runTime = " + dtTheCurrentSystemTime

are there any classes designed to allow me to monitor changes to the system
clock?

tks
Jul 19 '07 #2
You will want to use a System.Timers.Timer object and handle the Elapsed
event. In the handler, do the checks that you wish. I don't use database
scheduled events, so I cannot address that.

"Dica" wrote:
i'm working on a windows service that needs to check the system's clock
every minute and see if there are any jobs in my database taht are scheduled
to run at that time:

sSql = "select * from tblJobs where runTime = " + dtTheCurrentSystemTime

are there any classes designed to allow me to monitor changes to the system
clock?

tks
Jul 20 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: support | last post by:
Do you need to monitor websites for changes? iSpySiteWatch (http://www.ispysitewatch.com) is an Automated WebSite Monitoring system that can track changes on most websites. We've tested it to...
2
by: arcvonz | last post by:
We have a time critical smart client application running on Windows 2000/XP systems. Is there any reliable service that would help in syncing the local system time to atomic clock or local time at...
12
by: Brett Robichaud | last post by:
I need to make access to a reference object threadsafe. My natural instinct was to simply use Monitor.Enter() and Exit(). The problem is that the object behind the reference changes frequently,...
7
by: Dave | last post by:
Is there a way to query the monitor status, to know if it is on or off in C#? I found that WM_SYSCOMMAND is sent to WndProc when the monitor goes on and off but im not sure to find out if that...
1
by: MAB | last post by:
I need to create a service (or something else) to monitor the coming and goings of files (& possible folders) beneath a root folder. This service need to know the path/FileName of any new files so...
6
by: ewolfman | last post by:
Hi, Is there any way in which I can monitor / hook the Registry, and upon a call to a specific key from a specific application - swap the returned value? I was thinking of using this method...
1
by: jcor | last post by:
Hi, I already posted a similar problem, but now I have more concrete ideas of what I need. I'm trying to build a "drop box" so I can be watching a directory and every time a file is created I'll work...
2
by: samvb | last post by:
Hi, I have just finished a program that uses ms access and depends on system date to do certain things. just when i was testing it, a friend suggested that i change system date to see how it reacts....
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.