title: Razor Syntax gives errors in View before compiling (No intellisense)
body: <p>I was going through the list of NuGet Packages and I was updating everything things like bootstrap, jQuery, etc. but while I was doing that, I unthinkingly updated <strong>Microsoft.Owin</strong> and another package (might have been EF or something else) and it was a <strong>major version</strong> update...woops.</p>
  
  <p>I had to jump through hoops by deleting my project, getting an older version from source control and getting everything back to the right versions. Everything is back to normal and I have one last issue. <strong>Razor Syntax.</strong></p>
  
  <p>When I open up any of my views...anywhere in the project, I get this: 
  <img src="https://i.stack.imgur.com/pX4S4.jpg" alt="enter image description here"></p>
  
  <p>Notice how anything using Razor is marked with red error squiggle. They each say <strong>"The name '' does not exist in the current context"</strong>.</p>
  
  <p>When I close the file, no errors are shown. Also, when I run the project, there are no issues and everything works PERFECT. The problem is, I have no intellisense and it doesn't recognize any of my razor helpers. </p>
  
  <p>Here are the specifications for my project:</p>
  
  <pre><code>EntityFramework 6.0
  Microsoft.Owin 2.1.0.0
  Owin 1.0.0
  System.Web.Mvc 5.2.2.0
  System.Web.Razor 3.0.0.0
  </code></pre>
  
  <p>In my packages folder I also have:</p>
  
  <pre><code>Microsoft.AspNet.Mvc.5.2.2
  Microsoft.AspNet.Razor.3.2.2
  Microsoft.WebPages.3.2.2
  </code></pre>
  
  <p>I've modified my WebConfig to fix multiple errors and it now has the following code in it:</p>
  
  <pre><code>&lt;compilation debug="true" targetFramework="4.5.1"&gt;
        &lt;assemblies&gt;
          &lt;add assembly="System.Web.Abstractions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /&gt;
          &lt;add assembly="System.Web.Helpers, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /&gt;
          &lt;add assembly="System.Web.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /&gt;
          &lt;add assembly="System.Web.Routing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /&gt;
          &lt;add assembly="System.Web.Mvc, Version=5.2.2.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /&gt;
          &lt;add assembly="System.Web.WebPages, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /&gt;
        &lt;/assemblies&gt;
      &lt;/compilation&gt;
  </code></pre>
  
  <p>and under: <code>&lt;runtime&gt;&lt;assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"&gt;</code></p>
  
  <p>I have these:</p>
  
  <pre><code>&lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-1.5.2.14234" newVersion="1.5.2.14234" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="Microsoft.AspNet.Identity.Core" publicKeyToken="31bf3856ad364e35" culture="neutral" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-2.0.0.0" newVersion="2.0.0.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-4.5.0.0" newVersion="4.5.0.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="Microsoft.Owin.Security.OAuth" publicKeyToken="31bf3856ad364e35" culture="neutral" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-2.1.0.0" newVersion="2.1.0.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="Microsoft.Owin" publicKeyToken="31bf3856ad364e35" culture="neutral" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-2.1.0.0" newVersion="2.1.0.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="Microsoft.Owin.Security" publicKeyToken="31bf3856ad364e35" culture="neutral" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-2.1.0.0" newVersion="2.1.0.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="Microsoft.Owin.Security.Cookies" publicKeyToken="31bf3856ad364e35" culture="neutral" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-2.1.0.0" newVersion="2.1.0.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-4.2.1.0" newVersion="3.0.3.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" /&gt;
          &lt;bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="System.Web.Razor" publicKeyToken="31bf3856ad364e35" /&gt;
          &lt;bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-3.0.0.0" newVersion="3.0.0.0" /&gt;
        &lt;/dependentAssembly&gt;
        &lt;dependentAssembly&gt;
          &lt;assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" /&gt;
          &lt;bindingRedirect oldVersion="0.0.0.0-5.2.2.0" newVersion="5.2.2.0" /&gt;
        &lt;/dependentAssembly&gt;
  </code></pre>
  
  <p>And on each of the <strong>View folders</strong> in my project I have the following code inside of the <strong>Web.Config</strong> file:</p>
  
  <pre><code>&lt;configSections&gt;
      &lt;sectionGroup name="system.web.webPages.razor" type="System.Web.WebPages.Razor.Configuration.RazorWebSectionGroup, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"&gt;
        &lt;section name="host" type="System.Web.WebPages.Razor.Configuration.HostSection, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" /&gt;
        &lt;section name="pages" type="System.Web.WebPages.Razor.Configuration.RazorPagesSection, System.Web.WebPages.Razor, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" requirePermission="false" /&gt;
      &lt;/sectionGroup&gt;
    &lt;/configSections&gt;
  </code></pre>
  
  <p>Along with this code:</p>
  
  <pre><code>    &lt;system.web.webPages.razor&gt;
      &lt;host factoryType="System.Web.Mvc.MvcWebRazorHostFactory, System.Web.Mvc, Version=5.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" /&gt;
      &lt;pages pageBaseType="System.Web.Mvc.WebViewPage"&gt;
        &lt;namespaces&gt;
          &lt;add namespace="System.Web.Mvc" /&gt;
          &lt;add namespace="System.Web.Mvc.Ajax" /&gt;
          &lt;add namespace="System.Web.Mvc.Html" /&gt;
          &lt;add namespace="System.Web.Optimization"/&gt;
          &lt;add namespace="System.Web.Routing" /&gt;
          &lt;add namespace="IcapOrg" /&gt;
        &lt;/namespaces&gt;
      &lt;/pages&gt;
    &lt;/system.web.webPages.razor&gt;
  </code></pre>
  
  <p>I have tried uninstalling it, re-installing, upgrading, downgrading, removing and adding assemblies, and many more things I've started to forget. I'm not really sure where to move on from here. I can keep coding but it's just going to be a real pain without intellisense. Thank you in advance for any help.</p>