Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

VS 2008, .net 3.5 project in VS 2010: Could not load type ...EntityDesignerBuildProvider

I am trying to move a project from VS 2008 to VS 2010. The project upgrade wizard completed fine, but the project does not compile. It says:

C:\Windows\Microsoft.NET\Framework\v4.0.30319\Config\web.config(129): error ASPCONFIG: Could not load type 'System.Data.Entity.Design.AspNet.EntityDesignerBuildProvider'.

I have chosen to stay with .net 3.5, but from this error it seems like it is linking to version 4 of framework. If I right click on the solution and choose Properties, the Target framework on the Application tab is set to .NET 3.5

I have VS 2008 installed on the same computer, and the project compiles and runs fine.

Where am I going wrong?

like image 434
Palantir Avatar asked Aug 17 '10 11:08

Palantir


1 Answers

Make sure you have this in to your web.config.

<configuration>
  ...
  <system.web>
    <compilation debug="true" targetFramework="4.0">
      <assemblies>
        <add assembly="System.Security, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" />
        <add assembly="System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089" />
        <add assembly="System.Data.Entity.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089" />
      </assemblies>
      <buildProviders>
        <add extension=".edmx" type="System.Data.Entity.Design.AspNet.EntityDesignerBuildProvider" />
      </buildProviders>
    </compilation>
  </system.web>
</configuration>
like image 84
Carter Medlin Avatar answered Sep 30 '22 16:09

Carter Medlin