Getting the NT Server Time from Windows 98 client

How can i Get the Current Time of Windows NT Server while my
application is running on win98 client and then synchronize my workstation tiem with the server time
kakamnaAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

jclanzCommented:
hello,
Do the following command

NET TIME \\YOURSERVER /SET /YES

regards, jean-claude.
0
mikeblasCommented:
I'd assume that you want to do this programmatically, and not from the console manually. So:

The 15-point answer is: spawn the NET TIME command from your application.

The more expensive answer is to thunk a call to the 16-bit version of NetRemoteTOD() and deal with the results. Unfortunately, the 16-bit version of this routine is pretty buggy; it doesn't account for time-zone differences between the server and the client, so you'll need to work that out after you make the call yourself. NET TIME works around that bug for you, so it's probably your best bet.

..B ekiM
0
kakamnaAuthor Commented:

Actually I have used the Prot 37 but when i want to connect the socket the server refuses to get the result althogh there server of IBM AIX operating system is working fine with my routine. Now I want to know that waht kind of Services woulb be installed or have to enabled in order to communiate on port 37
0
Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

mikeblasCommented:
First, you said your server was running Windows NT.  Now, you're saying that your server is running AIX.

Which is it?  What's your _real_ question?

..B ekiM
0
kakamnaAuthor Commented:
Well I am trying to write an apllication whcihc can pick the time from the NT server I have wriiten a routine but when when i give the hostname of ntserver or win98 it does not work but when i use the host name of AIX the routine is Perfect. It means that there is nothing wrong at client side. In case of NT I rcieve Error Code 10061 which describes that there is problem on server side that either server has actively refused to give a connection or the desire service is not running. Now I want to resolve that problem
0
mikeblasCommented:
That just means that the Windows machine you're connecting to isn't running the time protocol server you expect.

If you want to use that protocol, you've got to install the software to support it. Once its running, it'll work just fine.

..B ekiM
0
kakamnaAuthor Commented:
What kind of software i need is available and where which can install time protocol
0
kakamnaAuthor Commented:
Adjusted points to 30
0
kakamnaAuthor Commented:
From Where can I get that Protocol or Software so That I become enale for communication on Port 37
0
mikeblasCommented:
Port 37 is for the Internet Time Protocol. It's described by RFC 868, which you can get at your favorite RFC site.

The protocol is very old, and has been largely usurped by SNTP. There are several SNTP client and server implementations available on the net.

..B ekiM
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
System Programming

From novice to tech pro — start learning today.