title: Powershell - convert local time to different timezone
body: <p>I am trying to convert my system time (EST) to a different timezone (GMT Standard Time) using PowerShell. I have to run this PowerShell command through my RPA automation software so I am looking to use a single command (instead of PS script) to accomplish this task if possible. Here's the command I am trying to use:</p>
  
  <pre><code>$test = Get-Date
  [System.TimeZoneInfo}::ConvertTime($test, 'GMT Standard Time')
  </code></pre>
  
  <p>First line is just to show the logic I am thinking but I will pass it as a variable and so that I truly have to execute only one line of code. However, I get the following error:</p>
  
  <pre><code>PS C:\Users\samsi&gt; [System.TimeZoneInfo]::ConvertTime($test, 'GMT Standard Time')
  Cannot find an overload for "ConvertTime" and the argument count: "2".
  At line:1 char:1
  + [System.TimeZoneInfo]::ConvertTime($test, 'GMT Standard Time')
  + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      + CategoryInfo          : NotSpecified: (:) [], MethodException
      + FullyQualifiedErrorId : MethodCountCouldNotFindBest
  </code></pre>
  
  <p>Clearly, I don't know much about PowerShell, can someone please help me with this command.</p>