ASP.NET MVC CRUD Tutorial

A comprehensive guide to building and deploying ASP.NET MVC applications

This sample CRUD application demonstrates how to create, read, update, and delete records using ASP.NET MVC. It covers various deployment strategies to Azure, including using Docker and GitHub Actions for continuous integration and deployment.

Comprehensive CRUD Implementation

Learn the fundamentals of create, read, update, and delete operations in ASP.NET MVC

Azure Deployment Strategies

Deploy your application using Docker, GitHub Actions, and modern CI/CD pipelines

Scalable Architecture

Build applications that scale with Azure App Services and Virtual Machines

Open-Source Project

Contribute to the project and collaborate with the community

Getting Started

Ready to get started? Explore the code and follow the steps to deploy your own ASP.NET MVC application to Azure. Stay tuned for upcoming features like integration with React, Vue, and mobile applications.

Project Documentation

SampleMvcCRUD (Web Distribution Summary)

A .NET 10 ASP.NET Core application showcasing multiple CRUD UI strategies (MVC, Razor Pages, AJAX modal CRUD, and PivotTable reporting) for Employees and Departments.

Key Features

  • MVC, Razor Pages, and Single Page style (AJAX + partial views)
  • PivotTable.js employee data analysis
  • Swagger/OpenAPI at /swagger
  • Bootswatch theme switching (light/dark)
  • In-memory EF Core data store
  • Health check at /health
  • Optional Azure Key Vault integration (via VaultUri env var)

Tech Stack

  • .NET 10 / ASP.NET Core
  • Entity Framework Core (InMemory)
  • Swashbuckle (Swagger)
  • Bootswatch (WebSpark.Bootswatch & WebSpark.HttpClientUtility)
  • Markdown rendering (Westwind)

HttpClient

HttpClient is used via WebSpark.HttpClientUtility to fetch Bootswatch themes from CDN sources for the dynamic theme switcher. Base AddHttpClient() is also registered for future external API use.

Run Locally

dotnet restore
cd Mwh.Sample.Web
dotnet run

Browse: https://localhost:5001

License

MIT � 2018-2025 Mark Hazleton