ZTree.com  | ZEN  | About...  

 Index   Back

[General] is there a way to append two lines to many text files?   [General]

By: Ben Kent       
Date: Jan 14,2022 at 08:46
In Response to: [General] is there a way to append two lines to many text files? (Ryan)

> alt="[image]" style="float: left; margin: 0px 5px 5px 0px" />
> something that took 0.5 sec finishing 200 batches took 10 minutes in
> powershell, made me wonder and checked the Inject-GamePath.ps1 said my
> powershell is offline but windows reported it online, i can open purple
> background powershell. it is there.
> i also remmber doing this fadedly...maybe long ago i kind of tangled
> with it to make it disabled. windowtweaker didnt have this feature to
> turn it on or off, it must not be it. it was interesting to meet pshell
> command for the 1st time. i will to fix it

You might have blocked execution of powershell.exe by doing this

But more likely, you haven't enabled the execution os scripts, see

i.e. these are not set
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\PowerShell" /v EnableScripts /t REG_DWORD /d 1 /f
reg.exe add "HKLM\SOFTWARE\Policies\Microsoft\Windows\PowerShell" /v ExecutionPolicy /t REG_SZ /d "Unrestricted" /f

If you want to run with the more restrictive RemoteSigned ExecutionPolicy, then call the powershell script from a local drive, or call the script with -ExecutionPolicy Bypass.

See here for ExecutionPolicy


Messages in this Thread

96,664 Postings in 12,235 Threads, 350 registered users, 200 users online (0 registered, 200 guests)
Index | Admin contact |   Forum Time: Jun 16, 2024 - 2:43 pm UTC  |  Hits:64,849,347  (59,407 Today )
RSS Feed