65 items found in the ASP.NET MVC Category

Entity Framework 6 Recipe: Storing And Managing Time

Thursday, April 23, 2015 1:19 PM

ASP.NET MVC Entity Framework

This post explores the options available to you when your application requirements include managing and storing time using the Entity Framework. Specifically, I am thinking of durations of time, such as the time required to complete some kind of task, not the time part of a date. Relevant examples might include storing the length of a movie, or the preparation time required for a recipe.

Click to read more about Entity Framework 6 Recipe: Storing And Managing Time ...

Viewed 497 times

2 Comments for this item

Sessions in ASP.NET 5

Tuesday, April 7, 2015 1:39 PM

ASP.NET MVC ASP.NET 5

ASP.NET 5 is being designed so that your application is only dependent on features that it actually needs. This is achieved in large part by creating a composable framework, where the developer opts in to non-essential features - a number of which are baked in to traditional versions of ASP.NET. One of the features that this applies to is Session State. This article looks at how to obtain and use session state in ASP.NET 5 applications.

Click to read more about Sessions in ASP.NET 5 ...

Viewed 10722 times

15 Comments for this item

ASP.NET 5 Middleware, Or Where Has My HttpModule Gone?

Tuesday, March 31, 2015 1:22 PM

ASP.NET MVC ASP.NET 5

ASP.NET 5 has been largely rewritten from the ground up, and incorporates some radical changes when compared with previous versions of ASP.NET. One of the biggest changes is in the HTTP Pipeline. This article looks at how those changes impact the design and registration of plug and play components that used to be represented by HttpModules.

Click to read more about ASP.NET 5 Middleware, Or Where Has My HttpModule Gone? ...

Viewed 9878 times

7 Comments for this item

How To Send Email In ASP.NET MVC

Tuesday, March 24, 2015 1:21 PM

ASP.NET MVC

This article takes a comprehensive look at the business of generating and sending email from an ASP.NET MVC application. It covers the most common use cases as well as some advanced scenarios. It also explores some of the more common errors that arise from attempting to generate and send email programmatically from an ASP.NET MVC site.

Click to read more about How To Send Email In ASP.NET MVC ...

Viewed 3672 times

4 Comments for this item

ASP.NET 5 By Numbers

Monday, March 16, 2015 1:20 PM

ASP.NET MVC ASP.NET Web Pages ASP.NET 5

There's a lot of confusion surrounding the numbers relating to the impending release of the next version of ASP.NET. This post takes a look at the main ones and seeks to explain their significance.

Click to read more about ASP.NET 5 By Numbers ...

Viewed 6085 times

1 Comment for this item

ASP.NET MVC DropDownLists - Multiple Selection and Enum Support

Tuesday, March 3, 2015 1:26 PM

ASP.NET MVC

My original article about Drop Down Lists in ASP.NET MVC has proven to be among the most popular on this site, amassing over a third of a million views since it was published 5 years ago. This article builds on the original by looking at using drop down lists for multiple selections, and the helper that was introduced in MVC 5.1 to support enumerations as a source of select options.

Click to read more about ASP.NET MVC DropDownLists - Multiple Selection and Enum Support ...

Viewed 12436 times

6 Comments for this item

Migrating From Razor Web Pages To ASP.NET MVC 5 - Model Binding And Forms

Tuesday, February 24, 2015 2:51 PM

ASP.NET MVC ASP.NET Web Pages

If you have built sites with the ASP.NET Razor Web Pages framework, you might want to look at migrating them to ASP.NET MVC at some point. This tutorial is the last in a series of three that explores how you do that by taking a step by step approach to migrating the WebMatrix Bakery template site to ASP.NET MVC 5. Previous tutorials in the series have looked at the roles of the View and Controller, and the data access and view model aspects of the Model. This final part covers model binding and form posting. A download (c. 24MB) featuring the completed application is available.

Click to read more about Migrating From Razor Web Pages To ASP.NET MVC 5 - Model Binding And Forms ...

Viewed 6065 times

2 Comments for this item

Migrating From Razor Web Pages To ASP.NET MVC 5 - Data Access And View Models

Wednesday, February 18, 2015 1:16 PM

ASP.NET MVC Entity Framework ASP.NET Web Pages

If you have built sites with the ASP.NET Razor Web Pages framework, you might want to look at migrating them to ASP.NET MVC at some point. This tutorial is the second in a series of three that explores how you do that by taking a step by step approach to migrating the WebMatrix Bakery template site to ASP.NET MVC 5. Along the way, each of the core parts of MVC are discussed by way of an introduction to the framework. The tutorial is divided into three parts. The first part looked at the roles of the View and Controller. This part looks at the M in MVC, the Model. Specifically, it features data access and view models. The final part will cover model binding and form posting. A download (c. 24MB) featuring the completed application is available.

Click to read more about Migrating From Razor Web Pages To ASP.NET MVC 5 - Data Access And View Models ...

Viewed 6281 times

0 Comments for this item

Migrating From Razor Web Pages To ASP.NET MVC 5 - Views and Controllers

Monday, February 16, 2015 1:33 PM

ASP.NET MVC ASP.NET Web Pages

If you have built sites with the ASP.NET Razor Web Pages framework, you might want to look at migrating them to ASP.NET MVC at some point. This tutorial is the first in a series of three that explores how you do that by taking a step by step approach to migrating the WebMatrix Bakery template site to ASP.NET MVC 5. Along the way, each of the core parts of MVC will be discussed by way of an introduction to the framework. The tutorial is divided into three parts. This first part looks at the V and C part of MVC - View and Controller. The M or Model is covered in the second and third parts. A download (c. 24MB) featuring the completed application is available.

Click to read more about Migrating From Razor Web Pages To ASP.NET MVC 5 - Views and Controllers ...

Viewed 6614 times

2 Comments for this item

MVC 5 with EF 6 in Visual Basic - Working With Files

Tuesday, January 27, 2015 1:26 PM

VB.Net ASP.NET MVC

This tutorial explores how to upload files in an ASP.NET MVC applications and how to use Entity Framework to store them in a database. It builds on a series of 12 that teach you how to build MVC 5 applications using Entity Framework for data access and Visual Basic. This tutorial does not have a counterpart in the original tutorial series, produced by Tom Dykstra and Rick Anderson ( @RickAndMSFT ) which was written using the C# language. A C# version is available here.

Click to read more about MVC 5 with EF 6 in Visual Basic - Working With Files ...

Viewed 6696 times

1 Comment for this item

ASP.NET MVC 5 with EF 6 - Working With Files

Tuesday, January 27, 2015 1:19 PM

ASP.NET MVC

This tutorial explores how to upload files in an ASP.NET MVC application and how to use Entity Framework to store them in a database. It builds on a series of 12 featuring the fictitious Contoso University that teach you how to build MVC 5 applications using Entity Framework for data access. The original tutorial series was produced in C# by Tom Dykstra and Rick Anderson ( @RickAndMSFT ) of Microsoft. This tutorial is coded in C#. As with the previous tutorials, I have produced a version that uses the Visual Basic language. It is available here.

Click to read more about ASP.NET MVC 5 with EF 6 - Working With Files ...

Viewed 25430 times

12 Comments for this item

Usage of the @ (at) sign in ASP.NET

Thursday, January 22, 2015 1:54 PM

C# ASP.NET MVC ASP.NET Web Pages Razor

The number of places where you might use or encounter the @ sign in ASP.NET has grown over the last few years and its exact purpose in all circumstances still seems to cause confusion. Here's an overview of the most common places that it crops up, and guidance on its correct usage.

Click to read more about Usage of the @ (at) sign in ASP.NET ...

Viewed 9125 times

4 Comments for this item

Entity Framework 6 Recipe - Grouping By Year And Month

Monday, January 12, 2015 8:38 PM

ASP.NET MVC Entity Framework

This is the latest in a series of "EF Recipes" - short articles that show through practical examples how to achieve common tasks with Entity framework and ASP.NET MVC. This particular example looks at grouping data by year and month in MVC 5 with Entity Framework 6. The article is prompted by an email I got from a reader who asked how I generate the "Archives" feature in the right hand panel on each page on this site.

Click to read more about Entity Framework 6 Recipe - Grouping By Year And Month ...

Viewed 9808 times

1 Comment for this item

Entity Framework 6 Recipe - Alphabetical Paging In ASP.NET MVC

Wednesday, October 29, 2014 8:53 PM

ASP.NET MVC Entity Framework

This article looks at using the alphabet for paging data in MVC 5 with Entity Framework 6. Where it differs from most existing articles on alphabetical paging is that this article looks at generating paging links from the data instead of the alphabet. It also features a Bootstrap-friendly helper for generating the paging links.

Click to read more about Entity Framework 6 Recipe - Alphabetical Paging In ASP.NET MVC ...

Viewed 17325 times

15 Comments for this item

Entity Framework 6 Recipe - Hierarchical Data Management

Friday, October 24, 2014 10:20 PM

ASP.NET MVC Entity Framework

This article explores how to use Entity Framework 6 to manage the retrieval and display of hierarchical data such as you might find in a menu system. There are a number of existing items on the Internet that cover the same topic, but most of them seem unnecessarily complex and don't include any information about displaying the data once it has been retrieved.

Click to read more about Entity Framework 6 Recipe - Hierarchical Data Management ...

Viewed 15881 times

4 Comments for this item

Recent Comments

kawish 4/24/2015 7:04 AM
In response to Using The Themes Helper In Razor Web Pages
Nice:)...

Mahdi 4/23/2015 9:49 PM
In response to Adding a New Row In The Razor WebGrid
Thank u very very. its useful for me...

Jerrie Pelser 4/23/2015 4:24 PM
In response to Entity Framework 6 Recipe: Storing And Managing Time
Nice article Mike! I think there is an error in the House property getter of MovieFormModel. Your...

mike 4/22/2015 4:45 PM
In response to Parameter Queries in ASP.NET with MS Access
If the insert statement got failed how w can i get the error message of as string?...

frank 4/22/2015 9:44 AM
In response to Sessions in ASP.NET 5
Mike can you write up an article showcasing the difference / upgrade paths of ASP.net Web Pages and...

Scott 4/21/2015 11:39 PM
In response to ASP.NET MVC DropDownLists - Multiple Selection and Enum Support
Excellent! Just what I need for the current application I am working on. Even to the extent that I a...

Benjamin 4/21/2015 4:57 AM
In response to Creating a Connection String and Working with SQL Server LocalDB
Hi Mike, great article. I am learning a lot. As commented @Evita, the <Key> Data Annotation is I...

Wayne Hudson 4/20/2015 9:14 PM
In response to Inline Editing With The WebGrid
Thank you very much for your articles. They've helped me a lot. How would you handle inline such...

Dan 4/20/2015 5:01 PM
In response to Sessions in ASP.NET 5
Can I ask how these sort of options are affected by the IIS configuration options when hosted in be...

Shaheen 4/20/2015 3:36 PM
In response to Conversion of a datetime2 data type to a datetime data type resulted in an out-of-range value
Perfect! Saved me from wasting hours....