[Windows] How to install / uninstall Cortana with a command!

IT / Computer

hello!This time, I would like to introduce commands related to installing and uninstalling Cortana.

There is a lot of information around Cortana in the streets, but there are cases where this alone cannot solve the problem.
It can be solved by reinstalling, but it may not work if it has been uninstalled.

To solve this, I searched for a command to install / uninstall independently, so please use it if you need it.

Thing you want to do

On Windows10, install / uninstall Cortana with a command.

Uninstalling is easy, just execute one command.

After uninstalling once, it is a little complicated to reinstall with a command, so I will explain in detail.

Script example (uninstall)

Get-AppxPackage -allusers Microsoft.549981C3F5F10 | Remove-AppxPackage

Commentary

Uninstall Cortana

Execute the command in the above script example with PowerShell executed by the administrator.

Cortana installation

Enter the following commands in order at the command prompt executed by the administrator.

d / d "C: \ Program Files \ WindowsApps"
dir | find / i "Microsoft.549981C3F5F10"

After entering the command, "Microsoft.549981CF ~~" is displayed as shown at the bottom of the red frame in the image below.

This isThe folder where Cortana is actually installedIt will be.

* Folder without "neutral"

 Displayed after entering the command ①Cortana installation folder nameCopy (= Microsoft.549981CF ~~) andUse the following command,Replace it with the copied Cortana installation folder name, and then enter it in PowerShell executed by the administrator.

In the case of the above image example, the command is as follows.

Get-AppXPackage -Name MicrosoDisableDevelopmentMode -Register "c: \ Program Files \ WindowsApps \Microsoft.549981C3F5F10_3.2202.10603.0_x64__8wekyb3d8bbwe\ AppxManifest.xml "}

④ Completed

Cortana will now be installed again.

Afterword

When you search the Internet for "Cortana installation command" etc., you often see the following commands that can be executed with PowerShell.

Get-AppXPackage -Name Microsoft.WindGet-AppXPackage -AllUsers | Foreach {Add-AppxPackage -DisableDevelopmentMode -Register "$ ($ _. InstallLocation) \ AppXManifest.xml"}

This command is"On a PC that already has Cortana installed, reinstall it for repair, etc.""In caseonlyIt works.

There is no doubt that both the method introduced this time and this command that often appears in searches are "Cortana reinstallation commands", but as in this case, "If you have already uninstalled CortanaToYou can only reinstall using the method introduced this time..

With this command, even if you uninstall Cortana once, the resource file of Cortana that was once installed remains, so it is moving to install it again using it.

I hope it helps you.

Comment

Translate »
I copied the title and URL