Archive for December, 2008

Debugging UI

Posted on December 15th, 2008 by aaron
Filed under .net, debugging, windows forms | 7 Comments

I’ve talked before about System.Threading.SynchronizationContext, as well as BeginInvoke/InvokedRequired/IsHandleCreated. In a multi-threaded Windows Forms application they can easily be mis-used, introducing difficult to find bugs.
One such not-so-subtle bug (application hang) is particularly nasty, and is described fairly well here. Distilled down, the application hangs, usually when the computer comes out of sleep mode, unlocks, or [...]

Case insensitive string comparisons with LINQ Dynamic Query

Posted on December 15th, 2008 by aaron
Filed under .net, tips and tricks | 6 Comments

LINQ rocks. It really does.
One down-side to LINQ is that, out of the box, it’s geared towards knowing your query structure at compile-time. The values can be dynamic, of course, but it’s assumed that the structure of your query is static. For example, if you want to select a set of "Person" objects from the [...]