title: Project references outside solution in VS2010
body: <p>According to <a href="https://stackoverflow.com/questions/2386238/tfsbuild-msbuild-and-project-reference-vs-file-reference/3069149#3069149">this</a> it should be possible to reference projects outside solution and have it working in VS and command line but not TFS.</p>
  
  <p>Unfortunately, when I've tried to partition my solution this way, it didn't work neither in VS2010/devenv nor in msbuild.</p>
  
  <p>In both cases the error was:</p>
  
  <blockquote>
    <p>The OutputPath property is not set for project 'Common.csproj'. 
    Please check to make sure that you have specified a valid combination
    of Configuration and Platform for this project.  Configuration='Debug'
    Platform='AnyCPU'.  This error may also appear if some other project
    is trying to follow a project-to-project reference to this project,
    this project has been unloaded or is not included in the solution, and
    the referencing project does not build using the same or an equivalent
    Configuration or Platform.</p>
  </blockquote>
  
  <p>However, current Platform is "x86" and no matter which platform and configuration I set in VS or msbuild it's always trying <code>Debug|AnyCPU</code>. In case of msbuild if I set <code>/p:OutputPath=bin\x86\Debug</code> it propagates to child projects correctly.</p>
  
  <p><strike>Is this a bug, can I work-around it ?</strike></p>
  
  <p><strong>UPDATE</strong></p>
  
  <p>Found the <a href="http://connect.microsoft.com/VisualStudio/feedback/details/643835/msbuild-uses-wrong-config-when-building-non-default-config-projects-referenced-but-not-included-in-solution" rel="nofollow noreferrer">bug in MS Connect</a>. Unfortunately closed as Won't Fix :(</p>
  
  <p><strong>UPDATE 2</strong></p>
  
  <p>Found workaround: set <code>ShouldUnsetParentConfigurationAndPlatform=false</code>. Both on command line for msbuild and in project file (before any imports) to fix Visual Studio.</p>