[visual-studio-2015] How to install Visual Studio 2015 on a different drive

I'm trying to figure out how to install Visual Studio Community 2015 on another drive besides my C:\ drive. Every time I open the installer of VS it shows the save location but won't let me change it:

visual studio install dialog with inactive path for install location

I'm wanting to change the download destination to my D:\ drive. If there is a work around could someone give me a hand? I've searched for about a few hours now, and I can't find anything relating to my issue.

This question is related to visual-studio-2015

The answer is


I use Xamarin with Visual Studio, and I prefer to move only some large android to another directory with(copy these folders to destination before create hardlinks):

mklink \J "C:\Users\yourUser\.android" "E:\yourFolder\.android"

mklink \J "C:\Program Files (x86)\Android" "E:\yourFolder\Android"

Use VirtualBox. Create a machine on the drive you wish. Enable guest aditions and activate seamless mode.

Benefits:

  • The ENTIRE installation is on the second drive. will work even with a 32gb ssd. (This is the main selling point, considering that Visual studio with it's additional features exceeds 30gb. If you have the GB to spare this solution is NOT the best for you)
  • Uninstalling or backing up is a breeze. Just delete or move the image file. No system file conflicts and dirty registry in case of a corrupted installation.

Drawbacks:

  • You need a LOT of ram. I use 4GB (out of 8) and 2 (out of 6) cores to run comfortably. Even so it is still slower than a normal installation.
  • Will not work for applications with extensive 3d graphics. If you want to work with forms it's fine but if you want to create a 3d game for android using say xamarin then forget it.
  • Testing the program takes several seconds to compile (minutes for android apps). This may not seem much but during development these seconds do add up.

This is the solution i am using and am very happy with it but i am not your average professional programmer. I just create small windows form applications like file uploaders, chat apps etc. Try it out. It will take some time to setup but this experimentation isn't risky.


Anyone tried this approach?

Doing a dir /s vs_ultimate.exe from the root prompt will find it. Mine was in <C:\ProgramData\Package Cache\{[guid]}>. Once I navigated there and ran vs_community_ENU.exe /uninstall /force it uninstalled all the Visual Studio assets I believe.

Got the advice from this post.


After trying to manually uninstall, and then downloading another copy of the VS 2015 community installer for use with the force uninstall command line argument (Original answer by Michael Schuchardt), I was still unable to modify the install directory.

After testing further, I found that Unity (which integrates with Visual Studio as of Unity 5.2) also had to be removed. At this point Visual Studio Uninstaller (link to latest release on Github) can be used for the final removal of remaining any remaining components.

You will now be able to run the Visual Studio Installer and select a directory or, alternatively, run the install from command line using the "/CustomInstallPath ..." argument.


Run installer in command line (Admin) with argument:

vs_community_ENU.exe /uninstall /force

Then:

vs_community_ENU /CustomInstallPath E:\VisualStudio2015


Uninstall the plugins first. And then try this. This uninstaller worked like a charm (I didn't even uninstall 2015 myself, it did everything on its own)!


I found these two links which might help you:

  1. https://www.reddit.com/r/csharp/comments/2agecc/why_must_visual_studio_be_installed_on_my_system/

  2. http://www.placona.co.uk/1196/dotnet/installing-visual-studio-on-a-different-drive/

Basically, at least a portion needs to be installed on a system drive. I'm not sure if your D:\ corresponds to some external drive or an actual system drive but the symlink solution might help.

Good luck