Supporting Multiple WS-Federation Authentication Schemes in ASP.NET Core

ASP.NET Core allows you to add support for multiple authentication schemes, such as social auth providers or WS-Federation. This support can be added with or without ASP.NET Identity Core. Users can then use these schemes to authenticate with your web application. While adding support for social authentication providers (such as Twitter and Facebook) is useful,Continue reading Supporting Multiple WS-Federation Authentication Schemes in ASP.NET Core

Changing Query String values in ASP.NET MVC

Recently I was trying to update a query string by adding or updating a parameter for URLs generated in a partial view. I found an excellent example for achieving this by setting route data here however this didn’t preserve current query string values in the URL. I’ve extended upon that code and updated it to include the queryContinue reading Changing Query String values in ASP.NET MVC

Disabling an ASP.NET MVC input control

I love ASP.NET MVC. It is a great framework to get web apps quickly built. However using the built in HtmlHelper methods on your views isn’t without its issues. An example of this is when trying to disable a HTML input control which has been built using HtmlHelper. You can add the “disabled” attribute which would beContinue reading Disabling an ASP.NET MVC input control

Fixed/Sticky Headers on ASP.NET GridView using jQuery

The GridView control in ASP.NET Web Forms is an extremely useful and quick way of getting data out to the user in a nice tabular format. It does have one weak spot though and that is some of the tags it uses when doing this. Specifically, not putting the header information inside a <thead> tag.Continue reading Fixed/Sticky Headers on ASP.NET GridView using jQuery

Strongly Typed Data in ASP .NET Web Forms

In ASP .NET Web Forms you’ve previously had to use strings to specify which properties you’d like to output when databinding, which would probably end up looking something like the following. In all likelihood it could probably look far less tidy if you’ve ever needed to do any formatting on values you’re about to outputContinue reading Strongly Typed Data in ASP .NET Web Forms

Send E-mail through Microsoft Exchange using .NET

Recently I needed to send an e-mail using Microsoft Exchange Server from an ASP .NET Web App. My first attempt involved using the classes in the System.Net.Mail namespace however I quickly realised this wasn’t the way to be going about it as I had very little luck getting a connection to the server. After a whileContinue reading Send E-mail through Microsoft Exchange using .NET

Using a RequiredFieldValidator on a DropDownList in ASP .NET

In most applications today drop-down lists default to a “Please select..” option with some form of validation to ensure the user makes their own selection. In ASP .NET web forms this frequently results in a drop-down list being created using code similar to that displayed below. We can add an ASP .NET RequiredFieldValidator and setContinue reading Using a RequiredFieldValidator on a DropDownList in ASP .NET

How to allow HTML content in ASP .NET MVC

Sometimes in web development, you need to provide an easy-to-use editor for non-technical users to input or change content where extra styling is required such as making text bold or italic. However unless you use (or code yourself) an editor which uses some form of BBCode you’re going to come across the following error message if you’re usingContinue reading How to allow HTML content in ASP .NET MVC

ASP .NET AJAX Control Toolkit Reorder List control and LINQ

The ASP .NET AJAX Toolkit is quite a useful and yet under-used set of controls. However they can also quickly lead to bizarre issues and worse performance than normal if they are not properly understood or used correctly. This issue is compounded when you take into consideration that quite a few of the controls included have a number of fairlyContinue reading ASP .NET AJAX Control Toolkit Reorder List control and LINQ