Accès refusé commande batch powershell ou autre

Fermé
adgm1 Messages postés 255 Date d'inscription jeudi 4 octobre 2007 Statut Membre Dernière intervention 9 avril 2024 - 19 nov. 2021 à 14:58
adgm1 Messages postés 255 Date d'inscription jeudi 4 octobre 2007 Statut Membre Dernière intervention 9 avril 2024 - 28 nov. 2021 à 22:16
bonjour. Je cherche à desinstaller une app de windows mais j'obtiens une erreur que je passe en batch ou en powershell. Accès refusé. C'est idem pour n'importe quelle commande batch. Une idée?

U:\1fichier batch>powershell -command "Get-appxpackage -allusers *xboxapp* | Remove-AppxPackage -allusers"
Get-appxpackage : Accès refusé.
Accès refusé.
Au caractère Ligne:1 : 1
+ Get-appxpackage -allusers *xboxapp* | Remove-AppxPackage -allusers
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Get-AppxPackage], UnauthorizedAccessException
+ FullyQualifiedErrorId : System.UnauthorizedAccessException,Microsoft.Windows.Appx.PackageManager.Commands.GetApp
xPackageCommand

6 réponses

brucine Messages postés 14190 Date d'inscription lundi 22 février 2021 Statut Membre Dernière intervention 16 avril 2024 1 785
19 nov. 2021 à 16:56
Bonjour,

Que ce soit via Batch ou Powershell, ces commandes doivent être exécutées en administrateur.
0