发布于 2年前
安装Visual Studio 2017报错:Error 0x80004003
在Windows 10安装Visual Studio 2017报错:
[9048:000e][2018-03-01T20:11:21] Error 0x80004003:
at Microsoft.VisualStudio.Setup.Cache.InstanceRepository.GetInstance()
at Microsoft.VisualStudio.Setup.Cache.CacheRepository.<GetInstances>d__27.MoveNext()
at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
at Microsoft.VisualStudio.Setup.Engine.VerifyInstallationPath(IServiceProvider services, String installationPath, IInstance instance, IQuery query)
at Microsoft.VisualStudio.Setup.Engine.Install(Product product, String destination, CancellationToken token)Object reference not set to an instance of an object.
在stackoverflow找的解决方案:
1、卸载之前安装的VS。
2、删除与之前安装VS相关的文件:
- C:\Program Files\Microsoft Visual Studio
- C:\ProgramData\Microsoft\VisualStudio
- %LocalAppData%\Microsoft\VisualStudio
在删除前可以先对它们备份。
3、重新安装