I’m fairly new to Silverlight but experienced in web development, and I’m finding myself highly annoyed with Silverlight’s default combobox. It seems to be lacking any concept of use for regular data entry. Primarily I’m wishing it would function like an HTML select box, where you can hit the drop down, then type a letter and it takes you down to the first item with that letter. Is there an easy way I’m missing to make it function like this, or a third party control that can do this?
Thanks!
You could write an attached behavior to provide this functionality. The problem is that the items in a
ComboBoxin Silverlight aren’t always strings. They may be entire controls that the user has templated as theItemTemplate. If you know yours are going to bestringyou can implement aBehavior<ComboBox>to attach to the KeyDown event and select the correct one.This is off the top of my head so it may not be exactly right and definitely lacks many safety checks, but it should give you an idea.