Could not load file or assembly ‘System.Data.Entity

To use an external Entity Framework model (embed in a DLL for example) with ASP.NET MVC 3 you must :

  1. Add the following reference to your MVC project : System.Data.Entity (Version, Runtime v4.0.30319)
  2. Add the following line in your web.config

< compilation debug="true" targetFramework="4.0">

    <add assembly="System.Data.Entity, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089" />

Leave a Comment