An easy stack layout panel for WinForms

This is a simple, but useful tip. Users of WPF are spoiled. They have all sorts of layout options. Those of us still working in WinForms have FlowLayoutPanel and TableLayoutPanel. That’s it. WPF has those and more.
For my current project, I needed a panel to layout controls vertically. The TableLayoutPanel can be awkward to work [...]

Popularity: 11% [?]

Converting OLE_COLOR to System.Drawing.Color

I’ve been working on a project using Visual Studio Tools for Office 2008 (VSTO) and at one point I needed to get the colors for categories in Outlook 2007. There are actually 3 colors, and they are returned as uint’s–why the .Net wrappers don’t convert to colors for you, I don’t know (to avoid linking [...]

Popularity: 10% [?]

Google Chrome - the Good, Meh, Ugly, and This Means War

I just read all about Google Chrome, their new open-source browser, in the comic they put out. No download link at this time, but I’m sure it’s coming. My initial thoughts:
The Good

The JavaScript changes seems to make sense. The better garbage collector and speed improvements can’t hurt.
The free API to download lists of [...]

Popularity: 10% [?]

Review: Pragmatic Unit Testing in C# with NUnit, 2nd Ed.

I saw this book when I bought Programming WPF a few weeks ago and it looked promising enough to buy. I’ve been doing unit testing in C# for a few years now, but I thought there were always things to learn and maybe I’d pick up a few new ideas.
It is easy to contrast this [...]

Popularity: 6% [?]

10 Ways to Learn New Things in Development

Expanding upon one of the topics in my post about 5 Attributes of Highly Effective Developers, I’ve been thinking of various ways to kick-start learning opportunities in my career and hobbies.
1. Read books. There are tons of books about programming–probably most of them are useless, but there are many, many gems that can greatly influence [...]

Popularity: 19% [?]

6 Ways to Increase Your Confidence As You Code

One of the key requirements for being able to reliably update software is the confidence that the changes you are making are safe. The amount of confidence required increases with the complexity of the system.
In my day job I work on a real-time messaging system that can have very, very little downtime. As the service [...]

Popularity: 19% [?]

Tip: Easily Automating use of WaitCursor

This is really simple and probably common, but it’s a useful tip anyway.
Say you need to set a form’s cursor to the wait cursor while you accomplish something.
You would do something like this:
this.Cursor = Cursors.WaitCursor;
 
//do something
 
this.Cursor = Cursors.Default;
Of course, what if “do something” throws an exception? Then your cursor won’t be set back to the [...]

Popularity: 7% [?]

.Net Reflector

Lutz Roeder’s .Net Reflector has been discussed on many blogs before, but I want to give it an additional plug. I recently had to emulate some C# serial-port code in our C++ app. The .Net SerialPort class is great, easy-to-use, and works well. Unfortunately, we’re using a C++ serial port library that does not support [...]

Popularity: 7% [?]

Podcasts I listen to

I got a 4 MB blue iPod Nano 2nd Genfor my birthday last June, and while I do have a few music playlists, I almost exclusively listen to podcasts. I can’t believe I went so long without one of these. Putting together the list below led me to some others that I might give a [...]

Popularity: 8% [?]

Easily Unit Testing Event Handlers

In C#, If you need to unit test a class that fires an event in certain circumstances (perhaps even asynchronously), you need to handle a little more than just running some code and doing the assertion. You have to make sure your unit test waits for the event to be fired. Here’s one naive way [...]

Popularity: 6% [?]