A collection of articles and tutorials on web development with ASP.NET by Mike Brind

Latest Entries

WebMatrix Opens Wrong Version Of Visual Studio

Sunday, May 1, 2011 8:56 AM

Visual Studio WebMatrix

A number of people have complained that clicking the Visual Studio Launch button in WebMatrix opens an older version of Visual Studio instead of the latest version. There is an easy fix to this.

Click to read more about WebMatrix Opens Wrong Version Of Visual Studio ...

Viewed 16955 times

9 Comments for this item

Generating RSS and ATOM Feeds In WebMatrix

Tuesday, April 12, 2011 12:36 PM

ASP.NET Web Pages WebMatrix Razor

I've previously looked at how to generate RSS feeds for both Web Forms and MVC using a variety of techniques, so it is only right that I look at a couple of ways to do this in Web Pages - the Razor based web development model supported by WebMatrix.

Click to read more about Generating RSS and ATOM Feeds In WebMatrix ...

Viewed 19164 times

3 Comments for this item

The Difference Between @Helpers and @Functions In WebMatrix

Sunday, March 20, 2011 9:42 AM

ASP.NET Web Pages WebMatrix Razor

This is another post which was inspired by a recent question in the ASP.NET forums, when someone asked what the difference is between @functions and @helpers in ASP.NET Web Pages. Here, I look at both of these contructs and explain what they are, how they are different, and how each should be used appropriately.

Click to read more about The Difference Between @Helpers and @Functions In WebMatrix ...

Viewed 70373 times

11 Comments for this item

Data Access Choices For WebMatrix

Saturday, March 5, 2011 10:46 PM

ASP.NET Web Pages WebMatrix

When WebMatrix was originally launched, it spurred a lot of activity from people who do not like seeing raw SQL statements in code files, or who perceived a problem working with dynamic objects. Some of these people threw their hands up in horror and tweeted or blogged their displeasure, while others felt the urge to do something about the "problem" as they saw it, and a number of open source data access projects have resulted. I've had a quick look at three projects to see what they might bring to the party.

Click to read more about Data Access Choices For WebMatrix ...

Viewed 40219 times

8 Comments for this item

Why You Can't Use Extension Methods With A WebGrid

Thursday, January 27, 2011 12:58 PM

Extension Method ASP.NET Web Pages WebMatrix WebGrid

An interesting question came up recently on the ASP.NET forums. In it, the questioner was attempting to use my Chop() extension method to limit the number of characters in a WebGrid column but it wouldn't work. At first, I was a little stumped, so I tried it myself and got an error message:

Click to read more about Why You Can't Use Extension Methods With A WebGrid ...

Viewed 11318 times

2 Comments for this item

I'm Writing A Book On WebMatrix

Tuesday, January 18, 2011 7:27 PM

ASP.NET Web Pages WebMatrix

Yes - it's official! I'm writing a book for Wiley all about Microsoft's new stack for beginner web developers - WebMatrix.

Click to read more about I'm Writing A Book On WebMatrix ...

Viewed 10228 times

28 Comments for this item

Creating A Custom Template For WebMatrix

Friday, January 14, 2011 11:57 PM

ASP.NET Web Pages WebMatrix

WebMatrix includes a number of pre-built templates that you can use as a basis for developing your site, but wouldn't it be great if you could add new ones? Well, there is a way to do so, and this article looks at the steps required.

Click to read more about Creating A Custom Template For WebMatrix ...

Viewed 28151 times

2 Comments for this item

The WebGrid Helper - Making Selections

Thursday, January 13, 2011 2:08 PM

ASP.NET Web Pages WebMatrix Razor WebGrid

The WebGrid helper, introduced via ASP.NET Web Pages, provides a means for displaying tabular data easily. This article examines how to enable selection within the WebGrid at row level.

Click to read more about The WebGrid Helper - Making Selections ...

Viewed 31194 times

6 Comments for this item

Razor, Cascading Select Lists and jQuery Templates - A New Twist

Tuesday, January 4, 2011 10:20 PM

jQuery ASP.NET Web Pages WebMatrix Razor

jQuery Templates enable easy client-side generation of html. When combined with JSON data or other JavaScript objects, jQuery Templates provide a way to create a dynamic data-driven site without any server-side code whatsoever. However, in this article I will look at how they can be used to produce cascading select lists in a Razor Web Pages site.

Click to read more about Razor, Cascading Select Lists and jQuery Templates - A New Twist ...

Viewed 31484 times

4 Comments for this item

WebMatrix - URLs, UrlData and Routing for SEO

Monday, December 20, 2010 12:56 PM

ASP.NET Web Pages WebMatrix Razor

There is a certain amount of debate surrounding the importance of friendly URLs in terms of Search Engine Optimisation and improving your ranking. One thing is certain - having friendly URLs helps users to identify whether the content at the end of a link to your site is likely to be relevant to them or not. This article examines how you can make use of the built-in support for Routing provided by ASP.NET Web Pages to not only create friendly URLs, but to work with parameters as well.

Click to read more about WebMatrix - URLs, UrlData and Routing for SEO ...

Viewed 42566 times

14 Comments for this item

Nested Layout Pages with Razor

Friday, December 17, 2010 1:27 PM

ASP.NET MVC ASP.NET Web Pages WebMatrix Razor

Razor Layout pages are the equivalent to MasterPages in ASP.NET Web Forms and the Web Forms View Engine within ASP.NET MVC. Just as it is possible to nest MasterPages, it is also possible to nest Razor Layout pages. This article explores the process required to achieve nesting of Layout pages using the Razor View Engine in MVC 3, or WebMatrix Web Pages sites.

Click to read more about Nested Layout Pages with Razor ...

Viewed 146193 times

9 Comments for this item

Building Mobile Apps with WebMatrix and jQuery Mobile

Sunday, December 12, 2010 9:52 PM

jQuery ASP.NET Web Pages WebMatrix Razor

jquery Mobile was launched just a month or so ago, and is designed to make it as easy to build JavaScript-enabled web applications for mobile phones as for the desktop browser. Still in Alpha, the library has a way to go, but it already offers a rather interesting experience when used as part of a mobile phone targeted web application. Here's a first look at how to use jQuery Mobile with WebMatrix to build a mobile web application.

Click to read more about Building Mobile Apps with WebMatrix and jQuery Mobile ...

Viewed 45480 times

7 Comments for this item

WebMatrix - Testing the WebImage Helper With JCrop

Sunday, October 17, 2010 9:06 AM

jQuery ASP.NET Web Pages WebMatrix

My original JCrop article which looked at cropping uploaded images in ASP.NET has proven to be the most popular coding article I've ever written, with more views and comments than any other. Revisiting JCrop in the context of Web Pages gives me the opportunity to have a look at the WebImage helper, and see how that might make uploading and cropping images easier.

Click to read more about WebMatrix - Testing the WebImage Helper With JCrop ...

Viewed 14033 times

5 Comments for this item

WebMatrix - Working With The JSON Helper

Friday, October 15, 2010 6:51 PM

jQuery ASP.NET Web Pages WebMatrix Razor

Javascript Object Notation (JSON) is a data exchange format which really grew in popularity as AJAX libraries took off. It's lightweight and human readable, and is a great way of transferring data structures between the browser and the server. The JSON Helper was added in WebMatrix Beta 2, and this article looks at its main methods, and how they can be used.

Click to read more about WebMatrix - Working With The JSON Helper ...

Viewed 32566 times

13 Comments for this item

WebMatrix - Protecting Your Web Pages Site

Sunday, October 10, 2010 8:04 PM

ASP.NET Web Pages WebMatrix Razor

Your Web Pages site is under threat. There are people out there who want to break into restricted areas, download files they shouldn't have access to, mess up your database and steal your passwords. Worse still, they want to use your application as a gateway to the web server so that they can take full control over it. This article examines those threats and how you can protect your application against them.

Click to read more about WebMatrix - Protecting Your Web Pages Site ...

Viewed 35894 times

4 Comments for this item

Recent Comments

Justin Kusuma 7/24/2015 3:38 AM
In response to Posting Data With jQuery AJAX In ASP.NET Razor Web Pages
Hi Mike, thanks much for sharing such an article :) Really help me a lot... further, I'd like to...

Michael Easterbrook 7/22/2015 5:35 PM
In response to Inline Razor Syntax Overview
I removed the @ symbols and I am still getting the same error. It only occurs when I have an "if" a...

Sujay 7/22/2015 1:36 PM
In response to ASP.NET MVC, Entity Framework, One-to-Many and Many-to-Many INSERTS
can you explain how to link two tables so that it forms many to many relationship?(Article and...

Max G 7/21/2015 9:29 PM
In response to Scheduled Tasks In ASP.NET With Quartz.Net
Hi, I've opted for this solution in one of my applications but i've found that the apppool is and I...

Michael Easterbrook 7/20/2015 4:31 PM
In response to Inline Razor Syntax Overview
When I have the following code: @foreach (var procRow in procRowDecade) { if (@procRow[3] +...

Shanice 7/18/2015 10:58 PM
In response to A Better Way To Export Gridviews To Excel
Hi. I'm working with mvc. I need to add the above code in the business logic layer, however the...

Matt 7/18/2015 6:29 PM
In response to Nested Layout Pages with Razor
Cheers sir, nice explanation :)...

Keshavan 7/17/2015 9:06 AM
In response to Scheduled Tasks In ASP.NET With Quartz.Net
Hi Mike, I have followed exactly as illustrated in blog, I get error "StdSchedulerFactory.cs" not...

Paul Thiel 7/16/2015 5:17 PM
In response to ASP.NET 5 By Numbers
Comments Below: "The new version of ASP.NET is called ASP.NET 5. It is a framework for developing...

saket singh 7/16/2015 8:42 AM
In response to Scheduled Tasks In ASP.NET With Quartz.Net
hi Mike, great tutorial on Quartz.net , but i have One Problem , Everything is working fine as as...