Here is the simple code snippet to find out the current time zone
Const HKEY_LOCAL_MACHINE = &H80000002
strComputer = "."
Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" & strComputer & "\root\default:StdRegProv")
strKeyPath = "SYSTEM\CurrentControlSet\Control\TimeZoneInformation"
strValueName = "StandardName"
oReg.GetExpandedStringValue HKEY_LOCAL_MACHINE,strKeyPath, strValueName,strValue
Set oReg=Nothing
Msgbox(strValue)
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment