This site uses cookies for analytics, personalized content and ads. By continuing to browse this site, you agree to this use.
Learn more
Developer Network
Developer Network
Developer
:CreateViewProfileText:
Sign in
Subscriber portal
Get tools
Downloads
Visual Studio
SDKs
Trial software
Free downloads
Office resources
Programs
Subscriptions
Overview
Administrators
Students
Microsoft Imagine
Microsoft Student Partners
ISV
Startups
Events
Community
Magazine
Forums
Blogs
Channel 9
Documentation
APIs and reference
Dev centers
Samples
Retired content
We’re sorry. The content you requested has been removed. You’ll be auto redirected in 1 second.
Microsoft Developer Network
>
Samples
>
ASP.NET MVC Application Using Entity Framework Code First
Download Visual Studio
Quick access
My samples
Upload a sample
Browse sample requests
ASP.NET MVC Application Using Entity Framework Code First
A Visual Studio 2013 project which shows how to use the Entity Framework 6 in an ASP.NET MVC 5 web application project, using the Code First development approach.
Download
C# (541.9 KB)
Ratings
4.4 Star
(184)
Downloaded
663,773 times
Favorites
Add to favorites
Requires
Visual Studio 2013
Updated
2/11/2017
License
Apache License, Version 2.0
Share
Technologies
ADO.NET Entity Framework
,
ASP.NET
,
ASP.NET MVC
,
Entity Framework
Topics
Asynchronous Programming
,
Entity Framework
,
Concurrency
,
Code First
,
Inheritance
,
Lazy Loading
,
ASP.NET Code Sample Downloads
,
Data Annotation
,
Code First Migrations
,
Eager Loading
,
Connection Resiliency
Report abuse to Microsoft
Description
Browse code
Q and A (74)
Solution explorer
C#
ContosoUniversity
App_Start
BundleConfig.cs
FilterConfig.cs
RouteConfig.cs
Content
bootstrap.css
bootstrap.min.css
PagedList.css
Site.css
Controllers
CourseController.cs
DepartmentController.cs
HomeController.cs
InstructorController.cs
StudentController.cs
DAL
SchoolConfiguration.cs
SchoolContext.cs
SchoolInitializer.cs
SchoolInterceptorLogging.cs
SchoolInterceptorTransientErrors.cs
fonts
glyphicons-halflings-regular.eot
glyphicons-halflings-regular.svg
glyphicons-halflings-regular.ttf
glyphicons-halflings-regular.woff
Logging
ILogger.cs
Logger.cs
Migrations
201411021828194_InitialCreate.cs
201411021828194_InitialCreate.Designer.cs
201411021828194_InitialCreate.resx
201411021834484_MaxLengthOnNames.cs
201411021834484_MaxLengthOnNames.Designer.cs
201411021834484_MaxLengthOnNames.resx
201411021841373_ComplexDataModel.cs
201411021841373_ComplexDataModel.Designer.cs
201411021841373_ComplexDataModel.resx
201411021957458_DepartmentSP.cs
201411021957458_DepartmentSP.Designer.cs
201411021957458_DepartmentSP.resx
201411022009135_RowVersion.cs
201411022009135_RowVersion.Designer.cs
201411022009135_RowVersion.resx
201411022351064_Inheritance.cs
201411022351064_Inheritance.Designer.cs
201411022351064_Inheritance.resx
Configuration.cs
Models
Course.cs
Department.cs
Enrollment.cs
Instructor.cs
OfficeAssignment.cs
Person.cs
Student.cs
Properties
AssemblyInfo.cs
Scripts
_references.js
bootstrap.js
bootstrap.min.js
jquery.validate.js
jquery.validate.min.js
jquery.validate.unobtrusive.js
jquery.validate.unobtrusive.min.js
jquery.validate-vsdoc.js
jquery-1.10.2.intellisense.js
jquery-1.10.2.js
jquery-1.10.2.min.js
jquery-1.10.2.min.map
modernizr-2.6.2.js
respond.js
respond.min.js
ViewModels
AssignedCourseData.cs
EnrollmentDateGroup.cs
InstructorIndexData.cs
Views
Course
Create.cshtml
Delete.cshtml
Details.cshtml
Edit.cshtml
Index.cshtml
UpdateCourseCredits.cshtml
Department
Create.cshtml
Delete.cshtml
Details.cshtml
Edit.cshtml
Index.cshtml
Home
About.cshtml
Contact.cshtml
Index.cshtml
Instructor
Create.cshtml
Delete.cshtml
Details.cshtml
Edit.cshtml
Index.cshtml
Shared
_Layout.cshtml
Error.cshtml
Student
Create.cshtml
Delete.cshtml
Details.cshtml
Edit.cshtml
Index.cshtml
_ViewStart.cshtml
Web.config
ContosoUniversity.csproj
favicon.ico
Global.asax
Global.asax.cs
packages.config
Project_Readme.html
Web.config
Web.Debug.config
Web.Release.config
ContosoUniversity.sln
Click an item in the panel on the left to view the contents here.