I know there is a registry key indicating the install directory, but I don't remember what it is off-hand.
I am currently interested in Visual Studio 2008 install directory, though it wouldn't hurt to list others for future reference.
The \Microsoft\VisualStudio\Shared directory is where Visual Studio stores the files that are shared by side-by-side Visual Studio installations. SDKs and tools are also stored in this directory.
Customizing the installation folders Visual Studio IDE: By default, the target path is C:\Program Files (x86)\Microsoft Visual Studio\2019\{editionName}. Download cache: By default, the target path is C:\ProgramData\Microsoft\VisualStudio\Packages.
In Visual Studio, the Tab 'Help'-> 'About Microsoft Visual Studio' should give you the desired infos.
If you've already installed it and want to change the location, you must uninstall Visual Studio and then reinstall it. In the Shared components, tools, and SDKs section, select the folder where you want to store the files that are shared by side-by-side Visual Studio installations.
I use this method to find the installation path of Visual Studio 2010:
private string GetVisualStudioInstallationPath() { string installationPath = null; if (Environment.Is64BitOperatingSystem) { installationPath = (string)Registry.GetValue( "HKEY_LOCAL_MACHINE\\SOFTWARE\\Wow6432Node\\Microsoft\\VisualStudio\\10.0\\", "InstallDir", null); } else { installationPath = (string)Registry.GetValue( "HKEY_LOCAL_MACHINE\\SOFTWARE \\Microsoft\\VisualStudio\\10.0\\", "InstallDir", null); } return installationPath; }
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With