Sunday 13 January 2013

Could not find the conceptual model type

I have been playing around recently with ASP .Net MVC, and after adding new tables to the Entity Framework model of my test app I started getting the following error:

"Could not find the conceptual model type"

After getting mad for a while I found the solution. For what I read around the web there is a bug with EF that causes problems when the .edmx file is in the same project as your models.

I moved the Entity Framework model to a separate new project in my solution and everything worked fine from there.

2 comments:

  1. I had the same problem recently and luckily dropped at your blog. Even i went mad thinking what i was doing wrong.

    For my solution, i moved the EDMX to different DLL project altoghther for sake of clarity following this article

    http://nullablecode.com/2013/09/splitting-entity-framework-model-classes-separate-projects/

    Thanks
    -Raj

    ReplyDelete
    Replies
    1. I am glad to hear that this old post in my dead blog was of use to you!

      Delete