PowerShell -ExecutionPolicy Unrestricted -Command "Remove-Item -Path…
- User
PowerShell -ExecutionPolicy Unrestricted -Command "Remove-Item -Path 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Appx\AppxAllUserStore\EndOfLife*' -Force -Verbose" Remove-Item : Requested registry access is not allowed. At line:1 char:1
- Remove-Item -Path 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\Ap ...
-
+ CategoryInfo : PermissionDenied: (HKEY_LOCAL_MACH...Store\EndOfLife:String) [Remove-Item], SecurityExce ption + FullyQualifiedErrorId : System.Security.SecurityException,Microsoft.PowerShell.Commands.RemoveItemCommand
- Assistant
The error message you're seeing indicates that the command you attempted to run does not have the necessary permissions to remove items from the Windows Registry. In particular, it's trying to modify a key within
HKLM:\SOFTWARE, which requires elevated permissions.Here's what you can try to resolve the issue:
-
Run PowerShell as an Administrator: To make changes to the hive of the registry, you need Administrator privileges. Right-click on PowerShell and select 'Run as Administrator'.
-