Building the Chapter Downloads for the EF 5 MVC 4 Tutorials
The Contoso University sample web application demonstrates how to create ASP.NET MVC 4 applications using the Entity Framework 5 Code First and Visual Studio 2012. For information about the tutorial series, see the first tutorial in the series.
Building the Chapter Downloads
- Download and unzip the project sample zip file. In the unzipped download package, you will find additional zip files, one for the completion of each chapter.
Right click on the desired zip file, click Properties, and click the Unblock button.
- Unzip the file.
- Double-click the CUx.sln file to launch Visual Studio.
From the Tools menu, click Library Package Manager, then Package Manager Console.
In the Package Manager Console (PMC), click Restore.
- Exit Visual Studio.
- Restart Visual Studio, opening the solution file you closed in the step above.
In the Package Manager Console (PMC), enter the
If you get the following error:
The term 'Update-Database' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
Exit and restart Visual Studio.
Each migration will run, then the seed method will run. You can now run the app.