Last night Doug Turnure came to give a presentation to the Birmingham Software Developers Association (BSDA). Doug is the Microsoft Developer’s Evangelist for Alabama / Georgia / Mississippi. Brian Hitney, Developer Evangelist for North and South Carolina happened to be in Atlanta where Doug lives, and came along.
Together, the pair did an excellent presentation on Vista. Doug started things out with the new gadget sidebar component, the various kinds of gadgets, and gave a demonstration on developing a gadget.
Brian then picked up the presentation, giving us a technical overview of the core changes to the OS. He covered a surprising amount of technical detail in the short amount of time he had, and made it understandable.
We had a packed room, but Doug and Brian stayed until they’d answered every question from the crowd. They did a great job, and I just wanted to take a moment to thank them publicly. The Developer Evangelists do a lot for us, they spend a lot of time away from home visiting user groups and giving us a lot of free training and advice.
Take time to get to know your developer evangelist, work with them to coordinate presentations at your user groups. And don’t forget to thank them when it’s all over. Thanks guys!
There are times when you need to sort your collection easily. Fortunately, there is a special dictionary called the SortedList to handle these needs. The SortedList is part of the System.Collections.Specialized library (don’t forget your using reference!).
There is one thing to understand that is a bit counter intuitive. The SortedList sorts off of the Key, and not the Value. While this may not seem natural, it can work to your advantage in times when users want to have peculiar sort orders. You can store the odd sort in the key, then display the values to the users.
In my simple example below, I’ve created a SortedList of the artists I might listen to during a day of programming. To make the sort case insensitive, I entered all the keys in lower case, then the value is the artist name in normal type.
SortedList myMusic = new SortedList();
myMusic.Add(“midnight synidicate”, “Midnight Syndicate”);
myMusic.Add(“kate bush”, “Kate Bush”);
myMusic.Add(“clint black”, “Clint Black”);
myMusic.Add(“queen latifah”, “Queen Latifah”);
foreach (DictionaryEntry favoriteArtist in myMusic)
Produces this output in the command window:
When you need to maintain a frequently changing list of values that need to be sorted, using the SortedList dictionary can be a real time saver.