none
Basic Powershell task - errors -Just trying to run excel, hidden on startup at each login.

    Question

  • Powershell.exe -File C:\ProgramFiles(x86)\MicrosoftOffice\root\Office16\excel.exe -ExecutionPolicy Unrestricted
    Start-Process -WindowStyle hidden -C:\ProgramFiles(x86)\MicrosoftOffice\root\Office16\excel.exe

     ####################################################################

    Error I get from Above:

    PS C:\WINDOWS\system32> C:\Temp2\be9.ps1
    File C:\Temp2\be9.ps1 cannot be loaded because running scripts is disabled on 
    this system. For more information, see about_Execution_Policies at 
    https:/go.microsoft.com/fwlink/?LinkID=135170.
        + CategoryInfo          : SecurityError: (:) [], ParentContainsErrorRecordExc 
       eption
        + FullyQualifiedErrorId : UnauthorizedAccess

    Help me out please.

    CT

    Tuesday, February 12, 2019 2:51 AM

All replies

  • What you are asking and the code posted make little or no sense.

    If running scripts is disabled then you cannot run any scripts.  We cannot help with this.  Ask your admins for help.


    \_(ツ)_/

    Tuesday, February 12, 2019 7:03 AM