My PC dont have microsoft store so i have to install it manually, but when i using command with admin powershell it just print an error, pls help me

Tak IsNoob 0 Reputation points
2023-06-14T03:45:09.3066667+00:00
Get-AppxPackage -allusers Microsoft.WindowsStore | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register “$($_.InstallLocation)\AppXManifest.xml”}


Add-AppxPackage : Deployment failed with HRESULT: 0x80070005, Access is denied.
Deployment Register operation with target volume C: on Package
Microsoft.WindowsStore_22304.1401.3.0_neutral_~_8wekyb3d8bbwe from:  (AppxBundleManifest.xml)  failed with error
0x80070005. See http://go.microsoft.com/fwlink/?LinkId=235160 for help diagnosing app deployment issues.
NOTE: For additional information, look for [ActivityId] 4ec27067-9e6e-0001-c1da-c24e6e9ed901 in the Event Log or use
the command line Get-AppPackageLog -ActivityID 4ec27067-9e6e-0001-c1da-c24e6e9ed901
At line:1 char:61
+ ...  | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register “$($_.I ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : SecurityError: (C:\Program File...ppXManifest.xml:String) [Add-AppxPackage], PSSecurityE
   xception
    + FullyQualifiedErrorId : DeploymentError,Microsoft.Windows.Appx.PackageManager.Commands.AddAppxPackageCommand

Windows for business | Windows Server | User experience | PowerShell
Microsoft Security | Intune | Configuration Manager | Other
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Limitless Technology 44,771 Reputation points
    2023-06-14T08:37:28.7266667+00:00

    Hello,

    Thank you for your question and for reaching out with your question today.

    The error message you received indicates that the deployment failed with an "Access is denied" error. This error typically occurs when the command is not run with sufficient privileges.

    To resolve this issue, try the following steps:

    1. Open PowerShell as an administrator: Right-click on the Start menu, select "Windows PowerShell (Admin)" or "Command Prompt (Admin)" to open an elevated PowerShell session.
    2. Run the command again: Copy and paste the following command into the elevated PowerShell window and press Enter:
    
    Get-AppxPackage -allusers Microsoft.WindowsStore | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register “$($_.InstallLocation)\AppXManifest.xml”}
    
    

    By running PowerShell as an administrator, you should have the necessary permissions to register the Microsoft Store app. This should resolve the "Access is denied" error.

    If the issue persists, you can try the following additional steps:

    1. Run the PowerShell command to set the execution policy: Open an elevated PowerShell window and run the following command to set the execution policy to "Bypass":
    
    Set-ExecutionPolicy Bypass
    
    
    1. Disable Windows Defender or other antivirus software temporarily: Some antivirus programs can interfere with app installations. Temporarily disabling them during the installation process may help. Remember to re-enable them after completing the installation.

    I used AI provided by ChatGPT to formulate part of this response. I have verified that the information is accurate before sharing it with you.

    If the reply was helpful, please don’t forget to upvote or accept as answer.

    Best regards.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.