< Back

Convert-Time

Mon Jan 13, 2020 5:13 am

NAME Convert-Time



SYNOPSIS

This command allows you to convert the time between the time zones





SYNTAX

Convert-Time [-InputTimeZone] <String> [-InputTime] <DateTime> [-TargetTimeZone] <String> [<CommonParameters>]





DESCRIPTION

This command allows you to input any standard time zone name and it's local time as an input and allows you to

convert the time to a different time zone. The script will take care about the day light savings on & off.





PARAMETERS

-InputTimeZone <String>



Required? true

Position? 1

Default value

Accept pipeline input? false

Accept wildcard characters? false



-InputTime <DateTime>



Required? true

Position? 2

Default value

Accept pipeline input? false

Accept wildcard characters? false



-TargetTimeZone <String>



Required? true

Position? 3

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>Convert-Time -InputTimeZone "GMT Standard Time" -InputTime "1/11/2018 10:20 AM" -TargetTimeZone "India

Standard Time"



InputTimeZone InputTime TargetTimeZone ConvertedTime

------------- --------- -------------- -------------

GMT Standard Time 1/11/2018 10:20:00 AM India Standard Time 1/11/2018 3:50:00 PM











RELATED LINKS