# Visual Studio 2017 path detection misses version folder

**URL:** https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081
**Category:** Bugs
**Created:** [March 11, 2017, 2:32am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081 "2017-03-11T02:32:09Z")
**Posts on this page:** 11
**Page:** 1

<div class="post-metadata">

### Author: ![catenalogic](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/catenalogic/32/116_2.png) [@catenalogic](https://www.finalbuilder.com/forums/u/catenalogic)
#### Post date: [March 11, 2017, 2:32am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/1 "2017-03-11T02:32:09Z")

</div>

Current logic is:  
  
Finds the path to executable ‘[devenv.com](http://devenv.com)’ for VS2017 in the registry key ‘HKLM\SOFTWARE\Wow6432Node\Microsoft\VisualStudio\15.0’ or checks the path ‘%PROGRAMFILES(x86)%\Microsoft Visual Studio\Community|Professional|Enterprise\15.0\Common7\IDE’   
  
Path logic should be:  
  
%PROGRAMFILES(x86)%\Microsoft Visual Studio\<strong\>2017\Community|Professional|Enterprise\15.0\Common7\IDE\<br\>

---

<div class="post-metadata">

### Author: ![catenalogic](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/catenalogic/32/116_2.png) [@catenalogic](https://www.finalbuilder.com/forums/u/catenalogic)
#### Post date: [March 11, 2017, 2:35am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/2 "2017-03-11T02:35:33Z")

</div>

Sorry, it also needs to remove 15.0:   
  
 “%PROGRAMFILES(x86)%\Microsoft Visual Studio\2017\Community|Professional|Enterprise\Common7\IDE”

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [March 12, 2017, 12:41pm UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/3 "2017-03-12T12:41:57Z")

</div>

Hi Geert   
  
 Actually the property collector is doing what it is supposed to, the description is wrong. It does look in the paths you suggest, as VS2017 doesn’t write the registry keys we relied on to find the install (I reported this during the beta but nothing has changed for the release). We’ll get the description updated.

---

<div class="post-metadata">

### Author: ![catenalogic](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/catenalogic/32/116_2.png) [@catenalogic](https://www.finalbuilder.com/forums/u/catenalogic)
#### Post date: [March 12, 2017, 2:25am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/4 "2017-03-12T02:25:12Z")

</div>

I’m not 100 % sure about it. I refreshed the properties on the agent quite some times, but it didn’t find it. After customizing the property collector to a Path Finder & customizing the path, it started working.   
  
 The Community|Professional|Enterprise had to be changed to professional in my case.

---

<div class="post-metadata">

### Author: ![Sparky](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/sparky/32/10_2.png) [@Sparky](https://www.finalbuilder.com/forums/u/Sparky)
#### Post date: [March 14, 2017, 8:11am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/5 "2017-03-14T08:11:10Z")

</div>

Hi Geert,  
  
The code does appear to be looking at the correct path and works correctly in our tests. As well as changing the display test, I’ve added some debug logging to the next version which we plan to release tomorrow. If you are able to send us a debug log after you install this, it will help us to understand what went wrong in your situation.

---

<div class="post-metadata">

### Author: ![catenalogic](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/catenalogic/32/116_2.png) [@catenalogic](https://www.finalbuilder.com/forums/u/catenalogic)
#### Post date: [March 15, 2017, 10:57am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/6 "2017-03-15T10:57:03Z")

</div>

Hi Dave,   
  
 Just updated and reverted my override. I want from 124 agent properties to 123 and VS 2017 is no longer available. Reverting back to a custom path finder with this value brings back the VS2017 installation.   
  
 I will email you the logs.

---

<div class="post-metadata">

### Author: ![catenalogic](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/catenalogic/32/116_2.png) [@catenalogic](https://www.finalbuilder.com/forums/u/catenalogic)
#### Post date: [March 15, 2017, 11:07am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/7 "2017-03-15T11:07:03Z")

</div>

Here are the logs:   
  
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] Opening registry subkey ‘SOFTWARE\Wow6432Node\Microsoft\VisualStudio\15.0\Setup’   
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] Opening registry subkey ‘SOFTWARE\Wow6432Node\Microsoft\VisualStudio\15.0\Setup’   
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] Checking for executable under ‘C:\Program Files (x86)’   
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] Checking the directory ‘C:\Program Files (x86)\Microsoft Visual Studio\Community\Common7\IDE’ for Visual Studio ‘15.0’   
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] The directory ‘C:\Program Files (x86)\Microsoft Visual Studio\Community\Common7\IDE’ for Visual Studio ‘15.0’ does not exist   
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] Checking the directory ‘C:\Program Files (x86)\Microsoft Visual Studio\Professional\Common7\IDE’ for Visual Studio ‘15.0’   
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] The directory ‘C:\Program Files (x86)\Microsoft Visual Studio\Professional\Common7\IDE’ for Visual Studio ‘15.0’ does not exist   
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] Checking the directory ‘C:\Program Files (x86)\Microsoft Visual Studio\Enterprise\Common7\IDE’ for Visual Studio ‘15.0’   
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] The directory ‘C:\Program Files (x86)\Microsoft Visual Studio\Enterprise\Common7\IDE’ for Visual Studio ‘15.0’ does not exist   
 Medium: 10:01:37.062 {T3} [Debug] [Visual Studio PlugIn] No installation path found   
  
 As you can see, it’s not adding the year to the path:   
  
 %PROGRAMFILES(x86)%\Microsoft Visual Studio\<b\>2017\Professional\Common7\IDE\

---

<div class="post-metadata">

### Author: ![Vincent](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/vincent/32/938_2.png) [@Vincent](https://www.finalbuilder.com/forums/u/Vincent)
#### Post date: [March 16, 2017, 12:44pm UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/8 "2017-03-16T12:44:16Z")

</div>

Hi Geert   
  
 Dave & I think we just figured it out… we’re parsing “15.0” to decimal, I suspect this is a locale issue as I seem to remember you use a comma as the decimal separator in the Netherlands. The reason it would only happen for 2017 is that the registry lookups will fail since the 2017 installer doesn’t write the registry entries (even though I reported it, and they said it would be fixed before release), when they fail we fall back to looking at paths.   
  
 The only reliable way to detect 2017 is by checking the standard install paths, if people install in non standard locations we have no way of finding it, and a manual override would be needed.

---

<div class="post-metadata">

### Author: ![Sparky](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/sparky/32/10_2.png) [@Sparky](https://www.finalbuilder.com/forums/u/Sparky)
#### Post date: [March 16, 2017, 1:50am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/9 "2017-03-16T01:50:39Z")

</div>

Hi Geert,  
  
Apparently 15.0 = 150 in the Netherlands:

`> ``using` `static` `System.Globalization.CultureInfo;`

`> DefaultThreadCurrentCulture = GetCultureInfo(``“nl-NL”``)`

`[nl-NL]`

`> ``decimal` `ver = 0;`

`> ``decimal``.TryParse(``“15.0”``, ``out` `ver)`

`true`

`> Write(ver)`

`150`

  

We’ve now fixed this code to parse the number using an invariant culture. You can download a new version using the following links:

[Continua CI Server Setup (64-bit) v1.8.1.366](http://downloads.finalbuilder.com/downloads/continua/1.8.1/Continuaci.server.setup_x64_1.8.1.366.exe)  
[Continua CI Agent Setup (64-bit) v1.8.1.366](http://downloads.finalbuilder.com/downloads/continua/1.8.1/Continuaci.agent.setup_x64_1.8.1.366.exe)

[Continua CI Server Setup (32-bit) v1.8.1.366](http://downloads.finalbuilder.com/downloads/continua/1.8.1/Continuaci.server.setup_1.8.1.366.exe)  
[Continua CI Agent Setup (32-bit) v1.8.1.366](http://downloads.finalbuilder.com/downloads/continua/1.8,1/Continuaci.agent.setup_1.8.1.366.exe)

Thank you for reporting this.

---

<div class="post-metadata">

### Author: ![catenalogic](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/catenalogic/32/116_2.png) [@catenalogic](https://www.finalbuilder.com/forums/u/catenalogic)
#### Post date: [March 16, 2017, 11:19am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/10 "2017-03-16T11:19:32Z")

</div>

Thanks, this fixes the issue, I now have 126 properties, so probably some other stuff has been fixed as well. In the Netherlands, the . is indeed a “visual separator” where the , is a “value separator” (so inverted from US).   
  
 I only noticed that it uses [devenv.com](http://devenv.com) instead of devenv.exe. I think this is not a real issue, just wanted to inform you about this as well.

---

<div class="post-metadata">

### Author: ![Sparky](https://www.finalbuilder.com/forums/user_avatar/www.finalbuilder.com/sparky/32/10_2.png) [@Sparky](https://www.finalbuilder.com/forums/u/Sparky)
#### Post date: [March 17, 2017, 7:45am UTC](https://www.finalbuilder.com/forums/t/visual-studio-2017-path-detection-misses-version-folder/6081/11 "2017-03-17T07:45:28Z")

</div>

Great that it is working now. Note that [devenv.com](http://devenv.com), which is a wrapper around devenv.exe, is preferred when running a command line as it delivers its output through&nbsp;standard system streams, such as stdout and stderr.
