Powershell Script 2 Command (ps2cmd)
Converts a Powershell script to a single Powershell Command. Use this as a work-around to run a Powershell script (normally a .ps1 file) when Powershell scripts are blocked from running on the system.
Steps
- Enter the Powershell Script (collection of commands) into the field below.
- Click “Convert”
- Select “copy to clipboard” link
- Open a Powershell window then Paste the Powershell Command into the Powershell window.
Powershell Command
powershell.exe -Command " # Generated Mon, 02 Dec 2024 19:55:56 +0000 Write-Host `"Hello World`" "