While executing Powershell “Invoke-Expression C:\Documents\UiPath\dummyp.ps1”
I am getting error :
System.Management.Automation.PSSecurityException: Cannot run software. Permission is denied.
UiPath\dummyp.ps1 cannot be loaded because running scripts is disabled on this system.
Try to run first this command and let us know:
set-executionpolicy unrestricted //No restrictions; all Windows PowerShell scripts can be run
if you have downloaded this dummy script or using from other system then you can use -
Set-ExecutionPolicy RemoteSigned // Downloaded scripts must be signed by a trusted publisher before they can be run.
Even if still things will not work then you can bypass your file from execution policy as well:
> powershell -ExecutionPolicy ByPass -File dummyp.ps1
Need more info to understand your problem and it would be great if you can share your sample workflow or steps with your sample powershell file.