ASP.NET entity datasource control error - The metadata specified in the connection string could not be loaded. Consider rebuilding the web project to build assemblies that may contain metadata.The following error(s) occurred. The provider did not return a Provider Manifest instance.

When you add an entity datasource control and you try to configure it you might get the following error:
The metadata specified in the connection string could not be loaded. Consider rebuilding the web project to build assemblies that may contain metadata.The following error(s) occurred.
The provider did not return a Provider Manifest instance.
Error trying to configure Entity Datasource control

In order to fix this you have to open your edmx file with notepad, locate ProviderManifestToken and change it's value from 2012 to 2008 as shown in the picture below. Save, rebuild in Visual Studio and you are done.



Comments

  1. It's very frustrating that this bug has been around so long and that Microsoft has basically said they do not intend to fix it. If they are not, and the bug is related to incompatible versions of VS and EF, they could at the very minimum publish a table of compatible components and features so that we don't need to spend hours futilely churning the web looking for threads of answers.

    ReplyDelete
  2. i love u man.....

    ReplyDelete
  3. Thanks a million you saved my day

    ReplyDelete
  4. thank you so much dude. For the Quick and Simple solution

    ReplyDelete
  5. I agree, its pathetic. Every newby who comes along stumbles into this and among the cloud of things needed to get a connection string right has to figure out this obscure bug. What is more disheartening is that Microsoft says that fixing it implies a significant change to their code. What sort of code architecture makes it difficult to fix a versioning bug?

    ReplyDelete
    Replies
    1. I agree it's so frustrating. In my current project I use Dapper. Maybe you would like to give it a try.

      Delete

Post a Comment

Popular posts from this blog

Convert Outlook EntryID to EwsID Exchange Web Services

Freeze panes in BO Webi report like Excel