title: Upgrading Monogame: The type exists in both Monogame and XNA
body: <p>I've just downloaded the newest version of Monogame (3.5) and I'm suddenly getting ambiguous references with XNA.  I'm not sure what version I had prior, but suffice it to say it's been a few years.</p>
  
  <p>I've tried adding and removing assembly references in Visual Studio, but this only generates different errors.</p>
  
  <p>Here's the exact message (one of them):</p>
  
  <pre><code>Error   12  The type 'Microsoft.Xna.Framework.Graphics.Texture2D' exists in both 'C:\Program Files (x86)\MonoGame\v3.0\Assemblies\WindowsPhone\x86\MonoGame.Framework.dll' and 'C:\Program Files (x86)\Microsoft XNA\XNA Game Studio\v4.0\References\Windows\x86\Microsoft.Xna.Framework.Graphics.dll'  c:\nightmare games\games\in production\boxland incorporated\boxland (monogame)\boxland\character_control.cs 55
  </code></pre>
  
  <p>I'm getting these for the following types:</p>
  
  <ul>
  <li>Texture2D</li>
  <li>GraphicsDevice</li>
  <li>Color</li>
  <li>Vector4</li>
  <li>MathHelper</li>
  </ul>
  
  <p><strong>UPDATE:</strong></p>
  
  <p>I've attempted to remove XNA from the project, using only Monogame.  Removing the assembly references and "using" statements results a multitude of "type or namespace not found" errors for the following types:</p>
  
  <ul>
  <li>Texture2D</li>
  <li>Game</li>
  <li>GameTime</li>
  <li>SpriteBatch</li>
  <li>SoundEffect</li>
  <li>and many others</li>
  </ul>
  
  <p>I already have the assembly reference to MonoGame.Framework.  Adding new using statements for MonoGame only resulted in the error:</p>
  
  <pre><code>Error   4   The type or namespace name 'MonoGame' could not be found (are you missing a using directive or an assembly reference?)  C:\Nightmare Games\Games\In Production\Boxland Incorporated\Boxland (monogame)\Boxland\Particle_Effects.cs  5
  </code></pre>
  
  <p><strong>UPDATE:</strong></p>
  
  <p>Project -> Properties -> Target Framework
  Changing this from ".NET Framework 4" to ".NET Framework 4.5" seems to fix the problem with Microsoft.XNA not being recognized, but this only generated new errors.</p>
  
  <pre><code>Error   2   The type or namespace name 'Graphics' does not exist in the namespace 'Microsoft.Xna.Framework' (are you missing an assembly reference?)    C:\Nightmare Games\Games\In Production\Boxland Incorporated\Boxland (monogame)\Boxland\Draw.cs  4
  </code></pre>
  
  <p>I'm now getting this for everything under the Microsoft.Xna.Framework umbrella, including Graphics, Input, Audio, Content, GamerServices, and so on.</p>