6

I'm trying to modify a predefined environment macros in Visual Studio 2015. Specifically this: VC_IncludePath

I can see it and its value, but I can not modify it. I don't see the option to do it.

Enter image description here

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131
ErnestM
  • 71
  • 1
  • 1
  • 3
  • 5
    *Don't*. This is a holdover from old versions and has been hidden and obscured greatly by Microsoft. Instead, just modify your projects to include the necessary additional folders. When you do it the way you are attempting, then each and every developer must change this too. If you make it a project setting, it is self contained. – crashmstr Jul 24 '15 at 17:34
  • @crashmstr The down-side of *not* doing it, is that it's including the wrong paths. So you need a function that exists in a version of `stdlib.h` in *this* SDK, but doesn't exist in *that* sdk path. We need some way to stop using old SDK paths. – Ian Boyd Jun 01 '20 at 19:08

4 Answers4

1

You can edit this file:

C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.Cpp.Common.props

Chewpers
  • 2,430
  • 5
  • 23
  • 30
1

The value of this macro is automatically generated from the versions you have set in the property pages. Select Project, Properties, Configuration Properties, General and check that the Target Platform Version and Platform Toolset are correct for your installation.

-1

For other versions, search 'Microsoft.Cpp.Common.props' in windows explorer at C:. You may find several depending on versions installed. Then, right click the version you want and Open > choose VS (easier to see the lists) or any. However, no VS environment variables are there to edit.

Meung Kim
  • 11
  • 2
-3

The place to change that environment variable is in the project property page Configuration Properties -> VC++ Directories as described in the MSDN documentation.

Khouri Giordano
  • 1,426
  • 15
  • 17