Quantcast
Channel: Virtual Machine Manager – General forum
Viewing all articles
Browse latest Browse all 2770

VMM Application Profile - Powershell Script

$
0
0

I have an Application Profile, that runs a script:

executable = cmd.exe

parameters = /c %windir%\system32\windowspowershell\v1.0\powershell.exe -executionpolicy bypass -file script.ps1 @param@

I'm changing the @Param@ ServiceSetting value at the point of creating a Service, however, i get an error at the point where the VM Guest is executing the script:  Error 22632 - which is complaining about the param function in my script which i have in place to capture the param input from the parameter line in the Application Profile (as above).

Essentially, what i'm trying to do is execute a powershell script via the Application Profile and pass in a variable - any advice is appreciated?  Thanks!


Viewing all articles
Browse latest Browse all 2770

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>