Calling Powershell Scripts
- Updated2025-04-10
- 1 minute(s) read
Create a custom execute to call a PowerShell script after you install a package. For example, you can invoke a PowerShell script that was installed as a temporary file, by the package, in a Post Install custom execute.
- Select [System (64-bit)] from the Root drop-down.
- Set the Relative Executable Path to the path of the
PowerShell executable:
WindowsPowerShell\v1.0\powershell.exe
- Enter the following PowerShell commands in the Arguments field to specify
the script and its arguments:
-File "<ScriptPath>" "<Argument-n>"
Replace <ScriptPath> with the full path for the script you want to call and repeat <Argument-n> as required.For example, the following command in a Post Install custom execute calls a PowerShell script, Temp File.ps1, that is installed to the [Temp] directory by the package, and passes two arguments:
-File "%Temp%\Temp File.ps1" "first argument value" "second argument value"
- Click OK.
- Build your package by selecting Build » Build All Packages.