MVC 4.0, Part 04 of 11: Working with Data
Interactive

MVC 4.0, Part 04 of 11: Working with Data

LearnNow Online
Updated Aug 22, 2018

Course description

If you need user input or output you will be working with Data. This course will start with making Models in the Entity Framework. Then you will learn about HTML helpers and what they can do for your views. Then you will be shown how to create Forms in MVC and explore the life cycle of posting changes.

Each LearnNowOnline training course is made up of Modules (typically an hour in length). Within each module there are Topics (typically 15-30 minutes each) and Subtopics (typically 2-5 minutes each). There is a Post Exam for each Module that must be passed with a score of 70% or higher to successfully and fully complete the course.


Prerequisites

This course assumes that you are familiar and experienced with Microsoft’s .NET Framework and ASP.NET development tools. You should be familiar with Web development and understand how HTTP and HTML work to produce Web pages for the user. You should have experience writing applications with ASP.NET 4.0 or later Web forms, and be familiar with how ASP.NET processes page requests, and have strong experience with .NET Framework 4.0 or later programming. You should have experience with Visual Studio 2012 for building Web application projects. Experience with building database applications using these tools will be helpful, although not strictly necessary.


Meet the expert

James Curtis

James Curtis is a .NET Developer that primarily works in the UX space. He has worked on and for several large projects alongside Microsoft Consulting. James has spoken at several code camps about UX development for ASP.NET and SharePoint. He is an active participant in the development community tweeting and blogging about several topics in the UX area. James is an active consultant and is also assisting in several Start-ups contributing his UX experience.

Video Runtime

82 Minutes

Time to complete

307 Minutes

Course Outline

Working With Data

MVC Models (20:06)

  • Introduction (00:23)
  • Making Entity Framework Models (01:05)
  • LINQ to SQL (00:54)
  • Entity Framework as MVC Model (01:12)
  • Demo: Creating MVC 4 Project (02:35)
  • Demo: Connecting to Database (05:03)
  • Demo: Entity Framework Model (01:33)
  • Display a List of Products (00:36)
  • Demo: Adding Product Controller (03:04)
  • Demo: Running the MVC App (03:23)
  • Summary (00:12)

HTML Helpers (19:56)

  • Introduction (00:24)
  • Introduction to HTML Helpers (02:03)
  • HtmlHelper Class (01:39)
  • Types of HtmlHelper Methods (00:17)
  • Untyped/Regular Helper Methods (01:04)
  • Strongly-Typed Helper Methods (00:45)
  • Templated Helper Methods (00:59)
  • Using View and Model Data (00:59)
  • Using HTML Helpers (00:31)
  • Input Element Helpers (00:21)
  • Templated Helper Methods (01:09)
  • Complex Helper Methods (00:18)
  • Creating Custom Helpers (00:31)
  • Demo: BeginForm HTML Helper (03:23)
  • Demo: GET and POST Methods (02:51)
  • Demo: HTTP Method Override (02:21)
  • Summary (00:14)

Input Element Helpers (22:20)

  • Introduction (00:30)
  • Demo: Model Attributes (01:58)
  • Demo: Edit Form (00:37)
  • Demo: Label (02:55)
  • Demo: EditorFor and Text Box (02:50)
  • Demo: HTML Rendered in Browser (02:00)
  • Demo: Form Validation Messages (02:14)
  • Demo: Radio Button (03:07)
  • Demo: Check Box (01:49)
  • Demo: Drop Down List (02:13)
  • Demo: Text Area (01:41)
  • Summary (00:20)

Filters (19:49)

  • Introduction (00:28)
  • Using Action Filters (00:44)
  • Types of Action Filters (00:34)
  • MVC Action Filters (01:37)
  • Authorize Action Filter (00:48)
  • Demo: Authorize Action Filter (02:19)
  • Demo: Authorizing User or Role (02:20)
  • HandleError Action Filter (00:40)
  • Demo: HandleError (03:12)
  • OutputCache Action Filter (00:39)
  • Demo: OutputCache (03:01)
  • RequireHttps Action Filter (01:07)
  • Global Filters (01:59)
  • Summary (00:13)