How to Run a PowerShell script inside a VBS script

To Run a PowerShell script inside a vbs script can be usefull for many reasons, and its a quick and dirty way to run PowerShell scripts in environments where execution policy normally stops you from running your scripts. A vbs wrapper script is what I use to launch PowerShell scripts in those scenarios.

This is the vbs wrapper i use to run PowerShell scripts.

Wrapper.vbs

Set objShell = CreateObject("Wscript.shell")
objShell.run("powershell -Executionpolicy Bypass -nologo -noninteractive -file .\script.ps1 -parameter Example")

Execute: cscript Wrapper.vbs

Note: You can also use this vbs script to run other vbs scripts inside the vbs script.

Ed Wilson (Microsofts scripting guy) also have a blog post about using vbscripts to run PowerShell. https://blogs.technet.microsoft.com/heyscriptingguy/2012/07/18/how-to-use-vbscript-to-run-a-powershell-script/