Hi All,
I'd like to write a small app to get the time from an "atomic" clock -- I believe the UTC time and then compare this against the system clock.
So far I've been able to get the system time details with the code below but just cannot figure out where to start on getting the atomic clock(s) time.
I did Google this for examples and have not found anything useful, I did find a list of atomic time servers @ the following URL and realise I have to connect to something but can someone give me some pointers pls.
NIST Internet Time Service clock
Dim localDirect As Date = Date.Now
Dim utcDirect As Date = Date.UtcNow
Dim localFromUtc As Date = utcDirect.ToLocalTime()
Dim utcFromLocal As Date = localDirect.ToUniversalTime()
Dim localMinusOffset As Date = localDirect.Subtract(TimeZone.CurrentTimeZone.GetUtcOffset(localDirect))
MessageBox.Show(localDirect.ToString("o"), localDirect.Kind.ToString())
MessageBox.Show(utcDirect.ToString("o"), utcDirect.Kind.ToString())
MessageBox.Show(localFromUtc.ToString("o"), localFromUtc.Kind.ToString())
MessageBox.Show(utcFromLocal.ToString("o"), utcFromLocal.Kind.ToString())
MessageBox.Show(localMinusOffset.ToString("o"), localMinusOffset.Kind.ToString())
I'd like to write a small app to get the time from an "atomic" clock -- I believe the UTC time and then compare this against the system clock.
So far I've been able to get the system time details with the code below but just cannot figure out where to start on getting the atomic clock(s) time.
I did Google this for examples and have not found anything useful, I did find a list of atomic time servers @ the following URL and realise I have to connect to something but can someone give me some pointers pls.
NIST Internet Time Service clock
Dim localDirect As Date = Date.Now
Dim utcDirect As Date = Date.UtcNow
Dim localFromUtc As Date = utcDirect.ToLocalTime()
Dim utcFromLocal As Date = localDirect.ToUniversalTime()
Dim localMinusOffset As Date = localDirect.Subtract(TimeZone.CurrentTimeZone.GetUtcOffset(localDirect))
MessageBox.Show(localDirect.ToString("o"), localDirect.Kind.ToString())
MessageBox.Show(utcDirect.ToString("o"), utcDirect.Kind.ToString())
MessageBox.Show(localFromUtc.ToString("o"), localFromUtc.Kind.ToString())
MessageBox.Show(utcFromLocal.ToString("o"), utcFromLocal.Kind.ToString())
MessageBox.Show(localMinusOffset.ToString("o"), localMinusOffset.Kind.ToString())