VS Code Failed to Install Visual Studio Code Update

37k Views Asked by At

I am trying to update my VS Code but am getting an error message: Updates may fail due to anti virus software and/or runaway processes.

A log file stemming from my Users was attached, but I am not sure what to check for. I am still new to computers and programming.

7

There are 7 best solutions below

0
Aventis On

I copied the Code.exe file from where my program was installed and pasted it to the temp map: C:\Users\YOUR_USERNAME\AppData\Local\Programs\Microsoft VS Code I reran the update and it works.

0
Josué Mendonça On

This happens because you installed VSCode in a specific directory, delete and download again but leave the default directory. This is because the update file looks for the default directory

0
Shashoto Nur On

Run the update setup file, with a name like "CodeSetup-stable-...exe", in the following location:

C:\Users\<:User>\AppData\Local\Temp\vscode-update-system-x64

Replace <:User> with your username. And make sure VS Code is closed.

The same problem happened to me as well. It was because I installed VS Code in another directory other than the default location. The problem happened because after downloading the update in the Temp directory, VS Code tried to locate the previous installation in the default location to update it. As it failed, the update setup file remained with the temporary files. The problem was solved by manually installing the update.

0
Jose P Fernandez On

This is how I resolved the problem:

  1. Close VSCode.
  2. Run VSCode AS ADMINISTRATOR by right clicking in the VS Code icon. This process opens VScode.
  3. Now run the same VSCODE update as usual from inside VSCode.
  4. VSCode closes after the update process and the latest VSCODE version is installed.
0
Marim mohamed On

This problem appeared to me because I moved the files of the setup of the vscode from Partition to another, and the solution was very simple. I opened the file that was in the path that appeared in the alert, and the problem was solved.

Just make sure any instance vscode was closed!

1
Mustafa Gökay Öztürk On

I had the same problem but mine was just about the name of the .exe . Be sure that name of the exe is Code.exe before doing other solutions

0
Preston On

For me I moved files from

C:\Users\<username>\AppData\Local\Programs\Microsoft VS Code\_

to (no underscore)

C:\Users\<username>\AppData\Local\Programs\Microsoft VS Code\

This fixed a broken Update that had been killed early by a reboot.