Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Question about net time dos command
Message
From
18/04/2004 23:16:50
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
 
To
18/04/2004 20:50:57
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00895989
Message ID:
00896002
Views:
11
>can i get the date and time generated by the dos command, net time \\domainserver1 ???

I assume the command sends output to the screen. You might redirect this command to a text file:
net time \\domainserver1 > timefile.txt
and then parse this file.

An option I have used to get the date and time, is to create a temporary file on the server, and get its date/time. The file will be created with the date/time of the server, not the user's machine. I don't know whether this applies to all combinations of NOS and workstations. I tried it with Windows NT server, and Windows 95 / 98 workstations.

HTH,

Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform