Tutorial by Examples

The -Command parameter is used to specify commands to be executed on launch. It supports multiple data inputs. -Command <string> You can specify commands to executed on launch as a string. Multiple semicolon ;-separated statements may be executed. >PowerShell.exe -Command "(Get-Date...
You can specify a file to a ps1-script to execute it's content on launch using the -File parameter. Basic script MyScript.ps1 (Get-Date).ToShortDateString() "Hello World" Output: >PowerShell.exe -File Desktop\MyScript.ps1 10.09.2016 Hello World Using parameters and argument...

Page 1 of 1