title: Running Invoke-AzureRmVMRunCommand through Azure automation
body: <p>I am trying to run a script thorugh Invoke-AzureRmVMRunCommand from azure automation but it is showing cmdlet does not exist. Please let me know how to implement this.</p>
  
  <h2>Below the script</h2>
  
  <pre><code>Invoke-AzureRMVMRunCommand -ResourceGroup 'XXXXXX' -Name XXXXX-CommandID 'RunPowerShellScript' -ScriptPath 'Test.ps1'
  </code></pre>
  
  <h2>Error details.</h2>
  
  <pre><code>Invoke-AzureRMVMRunCommand : The term 'Invoke-AzureRMVMRunCommand' is not recognized as the name of a cmdlet, function, 
  script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is 
  correct and try again.
  At line:1 char:1
  + Invoke-AzureRMVMRunCommand -ResourceGroup 'olf3em-rds-mgmt' -Name OLF   ...
  + ~~~~~~~~~~~~~~~~~~~~~~~~~~
  + CategoryInfo          : ObjectNotFound: (Invoke-AzureRMVMRunCommand:String) [], CommandNotFoundException
  + FullyQualifiedErrorId : CommandNotFoundException
  </code></pre>