Date object from server

I

Ike

Is there a way to obtaiun a date object from a server in an applet (I want
it to meake certain the user's clock on their local machine isn't set to a
date more than 24 hours away from this). Thanks, Ike
 
A

Andrew Thompson

Is there a way to obtaiun a date object from a server in an applet ..
yes

..(I want it to meake certain the user's clock
on their local machine isn't set to a
date more than 24 hours away from this).

Thanks, Ike

No worries,..
 
I

Ike

Yes Andrew, but I believe this is Windows-dependent (uses JNI down under the
hood). Thanks anyhow though -Ike
 
R

Roedy Green

Is there a way to obtaiun a date object from a server in an applet (I want
it to meake certain the user's clock on their local machine isn't set to a
date more than 24 hours away from this). Thanks, Ike

Have a look at http://mindprod.com/jgloss/setclock.html


It is overkill for what you want to do using atomic clocks.

If you can run a servlet on the server, it is trivial. Just return a
long timestamp.
 
R

Roedy Green

Yes Andrew, but I believe this is Windows-dependent (uses JNI down under the
hood). Thanks anyhow though -Ike

SetClock does use JNI to SET the user's clock, but it uses only
vanilla Java to find out the precise time.

It is quite a production. You might canibalise just the part that
sends a datagram to a time server and gets one back.

11,265 pcclock.jar -- native DLL for setting the clock
20,539 setclock.jar -- Java for getting the time and displaying it a
running display.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,768
Messages
2,569,575
Members
45,053
Latest member
billing-software

Latest Threads

Top