Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.


Windows 7: synchronizing time with w32tm.exe

08 Aug 2011   #1
EdN

Windows 7
 
 
synchronizing time with w32tm.exe

I run the following script, %windir%\system32\mysync.bat, in my startup menu.
What I want to do is resync the clock everytime I start up my desktop computer.

REM mysync.bat
REM synchronizes the clock
%windir%\system32\sc.exe start w32time
%windir%\system32\w32tm.exe /resync


It doesn't work. Why?
If I make a shortcut to mysync.bat and click on it
it works if I run it as administrator, but not otherwise.
How can I make the above script run with administrative privileges?


My System SpecsSystem Spec
.
08 Aug 2011   #2
logicearth

Windows 10 Pro (x64)
 
 

Why don't you just use the Task Scheduler?
Its what its there for.

Task - Create to Run a Program at Startup and Log On

Or you could let Windows handle it like it already does. There is already a task in Task Scheduler that handles updating the time.
My System SpecsSystem Spec
Reply

 synchronizing time with w32tm.exe




Thread Tools




Similar help and support threads
Thread Forum
Synchronizing with an Internet time server over HTTP
I cannot synchronize the time of my machine because the IT department blocks the related ports (I don't know why). Is there a practical way to synchronize the time over http?
Software
w32tm error; The RPC server is unavailable. (0x800706BA)
I have tried loads of things to solve this but I just can't do it. Please if you could help I would be very happy
Network & Sharing
Synchronizing subtitles with videos
I fixed this! if anyone need help pm me
Music, Pictures & Video
Synchronizing contacts between Win 7 and Vista Live Mail
I use windows live mail on both my Desktop with Win 7 and my laptop with Vista. What is the best way to keep my contacts list synchronized on both machines. Thanks, Bob
Browsers & Mail
Synchronizing Outlook and Nokia- calenders/contacts
I have Windows 7 on my laptop and desktop. On both I run Outlook 2010. I recently updated/removed duplicates/consolidated my contacts on Outlook 2010 as well as all the birthdays, etc on my calender. I have a Nokia E63 and downloaded Nokia Ovi Suite. My phone was previously backed up. I...
Microsoft Office
Outlook 2010 hung on synchronizing folders - need help
Hi all. I've just upgraded from office 2007 to 2010. Outlook 2010 imported my accounts and settings. I have 3 Gmail accounts set up in outlook. I use IMAP on all of them. My computer is running for 24 hours and it still says it synchronizing folders. ...
Microsoft Office


Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 11:39.

Twitter Facebook Google+



Windows 7 Forums

Seven Forums Android App Seven Forums IOS App