How do I uninstall “Microsoft .NET Core 1.0.0 RC2

2020-02-16 07:54发布

问题:

I'm having trouble uninstalling Microsoft .NET Core 1.0.0 RC2 - VS 2015 Tooling Preview 1. I'm in Windows 7, in the Programs and Features window. When I click uninstall, it brings up a dialog box, with the options repair, uninstall, and cancel. When I click uninstall, a "Open file" window pops up.

I've googled a bit to see if there's a file I can download to sate this "Open file" window. I can't find one anywhere. Here are a few of the things I have looked at, but I can't make sense of which one may fit.

https://www.microsoft.com/net/download

The reason I'm trying to uninstall this is because I'm having a lot of trouble with Visual Studio 2015 community, and this is part of the troubleshooting process.

回答1:

Download a copy of the installer exe from Microsoft:

  • DotNetCore.1.0.0.RC2-VS2015Tools.Preview1.exe
  • DotNetCore.1.0.0-VS2015Tools.Preview2.exe
  • DotNetCore.1.0.0-VS2015Tools.Preview2.0.1.exe
  • DotNetCore.1.0.1-VS2015Tools.Preview2.0.2.exe
  • DotNetCore.1.0.1-VS2015Tools.Preview2.0.3.exe
  • DotNetCore.1.0.1-VS2015Tools.Preview2.0.4.exe

After choose this file when asked. Then you can successfully remove it.



回答2:

In my case, I also had to manually start the .exe as Administrator, otherwise uninstall completes, but does not actually remove .NET Core installation.



回答3:

I hit a roadblock uninstalling Microsoft .NET Core 1.0.0 RC2 - VS 2015 Tooling Preview 1 as well. This is still an ongoing problem in 2020 as I am using Windows 10 :). Note that the original question by @r12 above was targeting Windows 7. However, I believe the Alternative Solution which I am providing in this response, is still an applicable solution model, to work with older versions of Windows as well.

When I visited the Programs and Features settings window and Clicked on Uninstall; I was experiencing the same 'Open file' dialog, which @r12 was experiencing. However again, I had the issue on Windows 10, whereas @r12 was using Windows 7. This lead me to believe it was a logic bug in the Uninstaller application specifically.

In addition, I encountered an annoyance after each failed uninstall attempt; where I could not perform a second uninstall attempt, without first rebooting. The rebooting between failed uninstall attempts was necessary, as the Programs and Features titled, informational wait dialog, with the label 'Please wait until the current program is finished uninstalling or being changed.', would appear for all subsequent Uninstall option Clicks. I waited beyond 10 minutes initially, on a Core i3. I gave up waiting and rebooted, instead of 'waiting it out', on what I presumed was a hanging state type of logic error in the Uninstaller application, that would never finish.

My assumption for why the Uninstall process is 'erring out early', is due to the 'Open file' dialog calling code in the Uninstall process is being returned an unexpected value, and is mishandling the result when no valid exe file is selected by the user in the 'Open file' dialog. The process is then 'erring out early' and bypassing the code that would notify Windows that the Uninstall process has been completed as cancelled by the user.

I also believe that having to select an exe file at all, during the Uninstall process, was never the intent for a normal end-user use-case, by the uninstaller application development team. This is significant in that, it further reveals a more complicated issue of having to do with the potential for it being related to IIS permissions or IIS file locking of the existing exe file or Uninstall/Install/Runner service.

I am thinking that IIS is potentially using the exe file or service/windows service as an operational resource, which should be more decoupled in nature; however, that this is interfering with the Uninstall portion of the service life-cycle. It appears that the default action of the Uninstall process, when encountering file-system related issues, could be to simply offer an 'Open file' dialog to the user. The purpose being, so the Uninstall developers and Uninstall testers of this service/windows service, can simply select a test exe file; which doesn't fully uninstall the service for speed in repeat test-ability.

I had also attempted to restart Windows prior to returning to the Programs and Features window again, however encountered repeat results. Some of you may be thinking of Albert Einstein stating 'The definition of insanity is doing the same thing over and over and expecting different results', as humor here in this cyclical reboot context. However, I hope you reconsider the fact I was already in the midst of uninstalling many applications and framework tools initially, prior to running into this problem, and simply had not rebooted yet :). When hitting application errors with any version of Windows, rebooting can be your first best option to a resolution. Although, I will say I was perhaps a bit zealous to even attempt an uninstall the third and fourth times after reboots, but lets just pretend I did not have high hopes.

I did find a separate Alternative Solution which did not require me to download any copies of the installer exe files, which had been linked in the previous solution answered by @Vincent Liou. For my specific example here, I assume I would have only needed to download the single exe file from Microsoft: DotNetCore.1.0.0.RC2-VS2015Tools.Preview1.exe, and then provide this to the Uninstaller application when prompted.

ALTERNATIVE SOLUTION: What I had done to to work around or fix the logic error in the already installed, uninstaller application/service, was to instead use the following instructions:

  • Visit the Programs and Features window.
  • Click on the link option Turn Windows features on or off.
  • Disable checkbox .NET Framework 3.5 (includes .NET 2.0 and 3.0).
  • Disable checkbox .NET Framework 4.7 Advanced Services.
  • Disable checkbox Internet Information Services.
  • Reboot.
  • Visit the Programs and Features window.
  • Select program Microsoft .NET Core 1.0.0 RC2 - VS 2015 Tooling Preview 1.
  • Click on the Uninstall link.

I was able to get the Microsoft .NET Core 1.0.0 RC2 - VS 2015 Tooling Preview service uninstalled correctly with this solution. I do not know if anything more than only IIS being disabled alone, was needed here. I was in the process of cleaning up, and uninstalling three older, Visual Studio software IDE's, and attempting to upgrade my Dev Box to a more current day, VS 2019 and .NET Core environment; which is why I thought to Disable checkbox .NET Framework 3.5 (includes .NET 2.0 and 3.0) and .NET Framework 4.7 Advanced Services. However, I do not know if this action was in fact, part of the solution. I also have no more time to dedicate to this.

Good luck and the Einstein quote was seen: professorbuzzkill.com/einstein-insanity-qnq and I also just linked this to a # hashtag, instead of the real link; because, I do not know if it is a safe link. Just search for it if you are unfamiliar, and are looking for the original source.