jeudi 26 novembre 2015

How to proceed with the given example?

In order to get a nice intro to asp.net mvc i started working on w3schools example. this example is super easy to understand and follow. I did exactly as shown in the below tutorials. [http://ift.tt/1Otmpye]

All steps prior to controller addition work fine But when i try adding a controller i get the below error:


Microsoft Visual Studio

Unable to retrieve metadata for 'MvcApplication1.Models.MovieDB'. Unable to cast object of type 'System.Data.Entity.Core.Objects.ObjectContext' to type 'System.Data.Objects.ObjectContext'.

I have looked for the similar error online and came across solutions that were created by using lower versions of entity framework. In my project i have installed entity framework 6 using nuget packages.

Guide me where I am wrong. I don't have any previous entity framework knowledge nor do I understand which suits which version of mvc.

As the example guides I created a asp.net mvc 3 web application using razor and html 5.

Please guide me where I am wrong or how to solve this?

Aucun commentaire:

Enregistrer un commentaire