Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to remove the clock (and access to the calendar)

Windows Scripting

How to remove the clock (and access to the calendar)

by  Mike Gagnon  Posted    (Edited  )
Note : The following will work on Windows XP and higher. To take effect a reboot or log off , log on is required.
To reverse the effect change the dwValue to 0.

Code:
#DEFINE HKEY_CURRENT_USER  -2147483647
strComputer = "."
oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\"+ strComputer + "\root\default:StdRegProv")
strKeyPath = "Software\Microsoft\Windows\CurrentVersion\Policies\Explorer"
strValueName = "HideClock"
dwValue = 1
oReg.SetDWORDValue(HKEY_CURRENT_USER,strKeyPath,strValueName,dwValue)

Mike Gagnon

Register to rate this FAQ  : BAD 1 2 3 4 5 6 7 8 9 10 GOOD
Please Note: 1 is Bad, 10 is Good :-)

Part and Inventory Search

Back
Top