Return the Current Time & Time Zone for all Exchange Servers in the Organisation:
$ExServers = Get-ExchangeServer
$ExServers | %{
$TimeZone = Get-WmiObject -Class win32_timezone -ComputerName $_
$LocalTime = Get-WmiObject -Class win32_localtime -ComputerName $_
$strOutput = @{‘Computer Name’ = $LocalTime.__SERVER;
‘Time Zone’ = $TimeZone.Caption;
‘Current Time’ = (Get-Date -Day $LocalTime.Day -Month $LocalTime.Month);
}
$Object = New-Object -TypeName PSObject -Property $strOutput
$Object
}