Brooke  Giles

Brooke Giles


Learn ASP.NET Core 5.0 MVC - CRUD Operations, EntityFramework Core

In this course you’re going to learn ASP.NET Core 5.0 MVC. We are going to go over the basics and build an Expense Tracker. To get the full 10h long course check out this: (Link will be added on Monday 25.01.21)

  • 00:00 Intro
  • 01:36 What we will build in this video
  • 06:21 Intro to the section
  • 07:20 The Tools you will need
  • 08:59 Introduction to .NET Core
  • 16:58 Creating an ASP.NET Core Project
  • 19:58 Project File and Program File
  • 24:10 Dependency Injection
  • 28:22 Startup file, .Net Core Pipeline and Middleware
  • 34:47 Routing in MVC
  • 40:52 Launchsettings, AppSettings, WWWRoot
  • 45:00 What exactly is MVC
  • 49:32 Shared Folder as well as ViewImports and ViewStart
  • 1:00:24 Intro To the Controller Chapter
  • 1:01:01 Creating your own controller in ASP.NET Core MVC
  • 1:06:40 Creating your own view in ASP.NET Core MVC
  • 01:10:48 Routing Explained
  • 01:18:35 Conventional Routing
  • 01:21:42 Attribute Based Routing
  • 01:24:19 Controller Actions
  • 01:26:24 Pass Values to Actions
  • 01:33:39 Action Return Types
  • 01:46:01 Intro Chapter Models
  • 01:47:00 Model in MVC
  • 01:53:37 Code First Approach and Migration
  • 01:58:32 Setting up the Connection String
  • 02:01:13 Setting up DBContext as Well es Entity Framework Core
  • 02:04:54 Setting up DBContext in our startup File in ASP.NET Core MVC
  • 02:08:52 Push our items to the Database, Migrations and checking the DB
  • 02:14:05 Add a controller to our borrowed items
  • 02:18:12 Passing Data to the Controller in ASP.NET Core MVC
  • 02:23:19 Displaying our Data using HTML and Bootstrap
  • 02:31:42 Add new columns to Database
  • 02:37:17 Create Page and Button editing
  • 02:42:57 Designing the create item page
  • 02:52:23 Creating the Entry in the Database
  • 02:58:42 Challenge - Expenses
  • 03:00:13 Challenge Expenses - Solution
  • 03:08:37 Server Side and Client Side validation
  • 03:20:11 Delete Entry in Database
  • 03:32:12 Update Entry in Databse

Learn ASP.NET Core 5
Learn Core MVC
You can learn ASP.NET Core MVC for programming web applications
General ASP.NET Core MVC tutorial
We are going to use HTML and bootstrap. core tutorial
You will first learn the ASP.NET core basics. Then we will dive deeper.
Best guide to core MVC
Learn the fundamentals of core MVC
The best core 5 MVC tutorial out there.
This is a video for core 5 MVC beginner

Here you can find the final code of the project:

#aspdotnet #web-development #developer

What is GEEK

Buddha Community

Learn ASP.NET Core 5.0 MVC - CRUD Operations, EntityFramework Core
Einar  Hintz

Einar Hintz


jQuery Ajax CRUD in ASP.NET Core MVC with Modal Popup

In this article, we’ll discuss how to use jQuery Ajax for ASP.NET Core MVC CRUD Operations using Bootstrap Modal. With jQuery Ajax, we can make HTTP request to controller action methods without reloading the entire page, like a single page application.

To demonstrate CRUD operations – insert, update, delete and retrieve, the project will be dealing with details of a normal bank transaction. GitHub repository for this demo project :

Sub-topics discussed :

  • Form design for insert and update operation.
  • Display forms in modal popup dialog.
  • Form post using jQuery Ajax.
  • Implement MVC CRUD operations with jQuery Ajax.
  • Loading spinner in .NET Core MVC.
  • Prevent direct access to MVC action method.

Create ASP.NET Core MVC Project

In Visual Studio 2019, Go to File > New > Project (Ctrl + Shift + N).

From new project window, Select Asp.Net Core Web Application_._

Image showing how to create ASP.NET Core Web API project in Visual Studio.

Once you provide the project name and location. Select Web Application(Model-View-Controller) and uncheck HTTPS Configuration. Above steps will create a brand new ASP.NET Core MVC project.

Showing project template selection for .NET Core MVC.

Setup a Database

Let’s create a database for this application using Entity Framework Core. For that we’ve to install corresponding NuGet Packages. Right click on project from solution explorer, select Manage NuGet Packages_,_ From browse tab, install following 3 packages.

Showing list of NuGet Packages for Entity Framework Core

Now let’s define DB model class file – /Models/TransactionModel.cs.

public class TransactionModel
    public int TransactionId { get; set; }

    [Column(TypeName ="nvarchar(12)")]
    [DisplayName("Account Number")]
    [Required(ErrorMessage ="This Field is required.")]
    [MaxLength(12,ErrorMessage ="Maximum 12 characters only")]
    public string AccountNumber { get; set; }

    [Column(TypeName ="nvarchar(100)")]
    [DisplayName("Beneficiary Name")]
    [Required(ErrorMessage = "This Field is required.")]
    public string BeneficiaryName { get; set; }

    [Column(TypeName ="nvarchar(100)")]
    [DisplayName("Bank Name")]
    [Required(ErrorMessage = "This Field is required.")]
    public string BankName { get; set; }

    [Column(TypeName ="nvarchar(11)")]
    [DisplayName("SWIFT Code")]
    [Required(ErrorMessage = "This Field is required.")]
    public string SWIFTCode { get; set; }

    [Required(ErrorMessage = "This Field is required.")]
    public int Amount { get; set; }

    [DisplayFormat(DataFormatString = "{0:MM/dd/yyyy}")]
    public DateTime Date { get; set; }


Here we’ve defined model properties for the transaction with proper validation. Now let’s define  DbContextclass for EF Core. core article core #add loading spinner in core core crud without reloading core jquery ajax form core modal dialog core mvc crud using jquery ajax core mvc with jquery and ajax core popup window #bootstrap modal popup in core mvc. bootstrap modal popup in core #delete and viewall in core #jquery ajax - insert #jquery ajax form post #modal popup dialog in core #no direct access action method #update #validation in modal popup

Einar  Hintz

Einar Hintz


MVC User Registration & Login with ASP.NET Core Identity

User registration and authentication are mandatory in any application when you have little concern about privacy. Hence all most all application development starts with an authentication module. In this article, we will discuss the quickest way to use **ASP.NET Core Identity for User Login and Registration **in a new or existing MVC application.

Sub-topics discussed :

  • How to add ASP.NET Core Identity to MVC application.
  • Customize ASP.NET Core Identity.
  • Identity.UI Design Customization.
  • Next step.


ASP.NET Core Identity is an API, which provides both user interface(UI) and functions for user authentication, registration, authorization, etc. Modules/ APIs like this will really be helpful and fasten the development process. It comes with ASP.NET Core Framework and used in many applications before. Which makes the API more dependable and trustworthy.

ASP.NET Core MVC with user authentication can easily be accomplished using Identity.UI. While creating the MVC project, you just need to select Authentication as Individual User Accounts.

Showing how to create an MVC application with ASP.NET Core Identity API

The rest will be handled by ASP.NET Core Identity UI. It already contains razor view pages and backend codes for an authentication system. But that’s not what we want in most of the cases. we want to customize ASP.NET Core Identity as per our requirement. That’s what we do here.

Create an ASP.NET Core MVC Project

First of all, I will create a brand new ASP.NET Core MVC application without any authentication selected. We could add ASP.NET Core Identity later into the project.

In Visual Studio 2019, Go to File > New > Project (Ctrl + Shift + N). From new project window, select ASP.NET Core Web Application.

Create an ASP.NET Core Web application

Once you provide the project name and location. A new window will be opened as follows, Select _Web Application(Model-View-Controller), _uncheck _HTTPS Configuration _and DO NOT select any authentication method. Above steps will create a brand new ASP.NET Core MVC project.

Select Model View Controller templet under .NET Core core article core #add core identity to existing project core identity in mvc core mvc login and registration #login and logout in core

Asp.Net Core MVC CRUD with EF Core

Create Asp.Net Core MVC Project

In Visual Studio, Goto File > New > Project ( Ctrl + Shift + N). Then select Asp.Net Core Web Application.

In template wizard, Select Web Application( MVC ) template. Make sure to select latest Asp.Net Core Version from top dropdown. We don’t need to configure this application with HTTPS (Unchecked corresponding option from bottom).

Setup Database for EF Core

For this application development, we will use EF Core – Code First Approach. First of all, we have to install NuGet Package for EFCore. for that you can right click on project in solution explorer, click on Manage NuGet Packages. In Browse tab, search for Microsoft.EntityFrameworkCore. Install the package with same version as that of Asp.Net Core.

We will create the DBContext class inside Models folder. To demonstrate Asp.Net Core CRUD Operation, we will deal with employee details like Full Name, Employee Code,Position and Office Location. So I have named the DbContext as EmployeeContext.

Copy to Clipboard

public class Employee
    public int EmployeeId { get; set; }

    [Column(TypeName ="nvarchar(250)")]
    [Required(ErrorMessage ="This field is required.")]
    [DisplayName("Full Name")]
    public string FullName { get; set; }

    [Column(TypeName = "varchar(10)")]
    [DisplayName("Emp. Code")]
    public string EmpCode { get; set; }

    [Column(TypeName = "varchar(100)")]
    public string Position { get; set; }

    [Column(TypeName = "varchar(100)")]
    [DisplayName("Office Location")]
    public string OfficeLocation { get; set; }

Inside the class, we have a DbSet property for Employees Collection of the type Employee class. So we have to define the class with required properties as follows. core core article core 2.2 core crud

Asp.Net Core MVC Bangla Tutorials - 47 (Complete eCommerce Application) core core mvc #Core core tutorials core with entity framework

Asp.Net Core MVC Bangla Tutorials - 14 (Complete eCommerce Application) core core mvc #Core core tutorialss core with entity framework