Try Now
More in this section

Forums / Developing with Sitefinity / Pluggable custom modules with Entity Framework

Pluggable custom modules with Entity Framework

2 posts, 0 answered
  1. Catherine
    Catherine avatar
    2 posts
    04 Oct 2013
    06 Nov 2013
    Link to this post
    To create a redistributable module that is compiled into a .dll for easy installation across
    multiple sites.

    I created a Custom Module Patient by  clicking my solution then Add Project--> Sitefinty Custom Module (My Data Provider is Entity Framework). I enabled automatic migrations and then created a widget to display all my patients in a RadGrid and everything is working well.

    When I add my Patient.dll to another website in a different solution,  I get this error when I try to create a patient: 
    Migrations is enabled for context 'PatientsEFDbContext' but the database does not exist or contains no mapped tables. Use Migrations to create the database and its tables, for example by running the 'Update-Database' command from the Package Manager Console.

    How do I fix this problem? I have been stuck on this issue for a week.
  2. Kaloyan
    Kaloyan avatar
    272 posts
    21 Oct 2016
    11 Nov 2013
    Link to this post
    Hi Catherine,

    Please check the following article from our documentation where you can find valuable information related to your desired scenario.

    Developing a Custom module using an Entity Framework data provider

    Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
2 posts, 0 answered