You must do this using the "Package Manager Console" (View> Other Windows> Package Manager Console).
Make sure that the class library project for which you want to enable migration is installed in the default project drop-down list, make sure you have a link to the Entity Framework DLL in the project, and then run enable-migrations .
To run update-database commands, etc., you need an app.config file that contains a connection string for each of your data contexts.
greg84
source share