My Blog is Moving

Hi folks – It’s that time again. Time to move my blog. Currently, my block is hosted on the MSMVPs site. It’s been a good place overall for my blog, but lately I’ve decided that I really want to take blogging more seriously, and the only way to do that is to do it right. The previous host seemed to have some stabilities issues, but I was happy there. Now, my blog is on my own domain, For now I will continue to cross post onto my old blog, but if you do have RSS feeds of Bookmarks to … Continue reading My Blog is Moving

Vitamin D, Sunshine, and Rainbows

Today is the start of me coming off of a client project that I have been on and off for years now. I really like the project and I tend to jump in when the client is planning some large items over the coming months. Sadly that reign has come to an end, and it’s off to different things. Regardless, a somewhat unique thing that we do as often as possible is work at the client’s location, their building, their office. While this provides enormous benefits when working with the client, it does mean that we take what we can … Continue reading Vitamin D, Sunshine, and Rainbows

Nastiness with Data in the .NET Compact Framework and the spiral downward (With Updates!)

The First Try As of late, if you for whatever reason on earth follow me on twitter, you might’ve picked up on the fact that I am working on a Windows Mobile project. Written in VB.NET. Here is my experience with working with a SQL database in the .NET Compact framework, and hopefully save someone some headaches. I naturally wanted to use SQL CE for a database. It comes out of the box, right? It’s made by the SQL team, which I usually have no problems with. SQL Server has been a solid Microsoft product for years, so let’s use … Continue reading Nastiness with Data in the .NET Compact Framework and the spiral downward (With Updates!)

ASP.NET AJAX 4.0 Client Template Rendering – The Observer Pattern – Part 2

We last left of here, about a simple introduction to the AJAX 4.0 Client Template Rendering. I’d catch up on that one if you haven’t read it before you read this one. Our last example was pretty simple. We took a chunk of JSON, and displayed it in an unordered list with simple JavaScript and the AJAX Framework. Let’s take this a step further with actually manipulating the data. The framework allows manipulation of data, and it does this with the observer pattern. The definition of the observer pattern is a bit weak, but Microsoft is advertising this as … Continue reading ASP.NET AJAX 4.0 Client Template Rendering – The Observer Pattern – Part 2

Centering Content Properly

As an ASP.NET Developer, not a designer, it’s pretty easy to write crappy HTML. As I have come to learn, content designers will hate you for that. One that has always fooled me is how to properly center content. Centered content is nice sometimes. It put information right in front of the users face, exactly where they expect it. HTML has come a long way since 2000, and it’s worth looking at some of the right and wrong ways to do it. Your designers will love you for it. The oldest, and simplest way to center content is to use … Continue reading Centering Content Properly

Enum Friendly

Have you ever seen a huge switch on an enum just to return a string? Enumerations can be tricky to deal with, mostly from the aspect of displaying them back to a user. So I whipped up a little code to make it easier to display enumerations, a little extension method. Consider this enumeration: public enum StatusEnumeration { Normal, NotRunning } If I want to display this back to a user in English, I can switch on the value, and return “Not Running” when the value is NotRunning. This can be a tad tedious, so I created an attribute to … Continue reading Enum Friendly

MVP 2009 and other stuff

Recently for April 1st I was re-awarded as an MVP for 2009, and I’m happy to be able to keep doing what I do for the community. So where has my blog been lately? Well I’ve been focusing on other things at the moment, but I am still blogging. I recently wrote a blog post for my company’s blog about refactoring, and getting your feet wet with it. We’ll see where the series goes too. You can read my blog post about refactoring here:

A Step Too Far

Occasionally, I have a bit of a compulsive behavior. When presented with a challenge, I usually won’t give up until I have a working answer… and sometimes that answer get’s a little crazy. Here’s one of my more recent journeys down that path. I was asked, “Hey Kevin. I am a method that accepts a type parameter, ‘T’. Is there a type constraint I can add to T so that I may sum them?” As an example, consider this code:  public string FormatNumber<T>(T t1, T t2) where T:IFormattable { T sum = t1 + t2; return String.Format(“{0:N2}”, sum); } This … Continue reading A Step Too Far