cycledude
asked on
C# 2010 Winforms get LAN server datetime
Hi
I have a requirement to get the datetime from the local network server, and not rely on users having correct datetime on their system..
How can I get the 'actual' datetime from the local server?
Cheers
CD
I have a requirement to get the datetime from the local network server, and not rely on users having correct datetime on their system..
How can I get the 'actual' datetime from the local server?
Cheers
CD
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ntp1.ja.net is indeed a internet server, but you presumably can use a "internal" server for that.
ASKER
LAN restrictions are blocking access...
ASKER
one thing that may be possible...
I have an access database that the application connects to... this is stored on a local server.
Is it possible to retrieve the server date/time via access?
I have an access database that the application connects to... this is stored on a local server.
Is it possible to retrieve the server date/time via access?
not that I know of ...
but again: the time server doesn't need to be a "internet" server.
your domain should have a time server, just use that one instead.
I don't think it should be "blocked"
but again: the time server doesn't need to be a "internet" server.
your domain should have a time server, just use that one instead.
I don't think it should be "blocked"
ASKER
well, I tried replacing the '("ntp1.ja.net") with ("localservername");
and it did the same thing... just hung the application....
and it did the same thing... just hung the application....
you will have to check with the relevant network admins about this issue...
ASKER
I have accepted this as an answer, although it did not work for me...
ASKER
Thanks, I will try it, but it looks like it's getting the time from the internet... a problem I have (which I probably should have mentioned) is that not all users on the network have internet access rights on their windows login..