<p>I have a solution of mixed VB.NET and C++ projects. When using Visual Studio 2005 you can set the "Tools->Option->Projects and Solutions->VC++ Directories" to help the compiler find your include files. When building the same solution with MSBuild I don't see how to pass these settings. The C++ won't compile without this path specified. When building this solution form Visual Studio it build perfectly.</p>

<p>What is the way to pass this path for MSBUild?</p>

<p>Edit: Looks like MSBuild doesn't pass the path (or the /u switch) to vcbuild. Starting from VCBuild instead fails on dependency.</p>

To set the include directories, you can add them into your INCLUDE environment variable. You use the same format as in PATH env. variable - you separate paths with semicolons.
To set the library directories - you can do it in similar way, by putting them into your LIB environment variable.
To set environment variables, you simply right-click "My Computer", choose "Properties". Then you go to "Advanced" tab, and there's a button called "Environment Variables".
Or, you can run MSBuild from a BATCH script, in which case, before calling MSBuild, you can set the INCLUDE and LIB variables, like so:
```
```
set INCLUDE=C:\Libraries\LibA\Include
set LIB=C:\Libraries\LibA\Lib\x86
```
```