header image

W2KSG: Time Zones

Posted by: | September 25, 2008 | No Comment |

The WMI section of the scripting guide gives a very simple method of determining the time zone on your machine

Listing 6.20

Get-WmiObject Win32_TimeZone | Format-List

Bias      : 0
SettingID :
Caption   : (GMT) Greenwich Mean Time : Dublin, Edinburgh, Lisbon, London

Bias returns the offset from GMT and the caption returns the time zone.  Information on daylight saving settings is also available – try get-member on it!


Share this post :


Technorati Tags: ,

under: PowerShell and WMI