Generics

There are 1 entries for the tag Generics
Binding Complex Types to WinForms TreeView with Extension Methods and Generics

So it turns out that the WinForms TreeView control doesn't support binding anything but a Text property to its nodes. This is a pretty lame oversight given what the control is used for (displaying a set of hierarchical data) and we had a need to find a way to bind complex types to the thing. Were this a few months ago we would have had to subclass the control, take in Objects, and do awkward things to make it happen. But now that .net 3.5 is my bff, a quick combination of extension methods and generics will do...

posted @ Friday, August 15, 2008 10:27 AM | Feedback (0)