API call to return a specific machines system clock 
Author Message
 API call to return a specific machines system clock

Hi,

I was just wondering if there exists an API call that returns the system
clock from a specific machine, say, where the .exe resides.

Thanks,

Iain



Mon, 06 Sep 2004 20:24:08 GMT  
 API call to return a specific machines system clock
No. There are some internet protocols (NTP, Network Time Protocol) that can retrieve this,
but it will always be skewed by some amount (the usual trick is to query the time several
times and measure the delay in the response and divide by two. The question of
synchronizing times is essentially unsolvable, although you can use tricks like this to
synchronize two clocks to within a few milliseconds. NTP requires the other machine be
running an NTP server (I think XP machines do this, but I had to install it on my NT 4.0
sever).
                                        joe

Quote:
>Hi,

>I was just wondering if there exists an API call that returns the system
>clock from a specific machine, say, where the .exe resides.

>Thanks,

>Iain

Joseph M. Newcomer [MVP]

Web: http://www3.pgh.net/~newcomer
MVP Tips: http://www3.pgh.net/~newcomer/mvp_tips.htm


Tue, 07 Sep 2004 01:58:29 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Calling system clock from application.

2. Q: update system clock with real time clock

3. HELP!ODBC API call SQLFetchScroll returns Access violation with ODBCCR32.dll

4. C99 restrict keyword (as used in POSIX system call API method)

5. API and system call?

6. call system() in linux return code = 2560

7. Q: Return-values of system("...") calls

8. system call to return current line number

9. system call to return current line number

10. system call to return current line number

11. Help: C system call that returns list of all processes in Unix

12. weird machine specific bug

 

 
Powered by phpBB® Forum Software