execution policy suggestions
hi,
i seeking suggestions setting execution policy, there scripts have written shared people dont know powershell, if give them script , ask them set execution policy before running script may become bit pain them (of course there doc how screenshots) , planning set execution policy through script everytime or 1 time or whatever. there scripts used once in week , there running scheduled tasks , should scripts running once has mandatory parameters. in case of parameterised script not able set execution policy @ top, not sure why. can throw light on this
try running .ps1 using command
powershell.exe -executionpolicy bypass -nologo -noninteractive -noprofile -windowstyle hidden -file <path_to_script_name>
this bypass execution policy.
(please click on "vote helpful" and/or "mark answer", if has helped you. )
Windows Server > Windows PowerShell
Comments
Post a Comment