Thumbnail View Resource
Source (Bea Stollnitz on Silverlight and WPF), posted 2008-12-31

Added By

Avatar BillHenn on 2008-12-31

  • 4226 total views
Shows how to expand and select TreeView items using the Dispatcher.
"This is the third of a three-part series about expanding TreeViewItems. In the first post I explained how to use an implicit Style to expand all TreeViewItems at load time. In the second post I showed how you can drive expansion and selection of items using an intermediate data source. In this post, I will explain how you can expand and select TreeViewItems using the dispatcher. Expanding all TreeViewItems by setting the IsExpanded property on the items directly is not as simple as doing a tree walk and marking this property as you go. The problem is that after expanding a TreeViewItem, you need to return control to WPF or Silverlight so that the children TreeViewItems can be instantiated, before it’s their turn to be expanded. Fortunately, the Dispatcher can be used on both of these technologies to ensure the instantiation of the TreeViewItems."
Full Link

About Bea Stollnitz on Silverlight and WPF

Bea an independent software consultant specializing in WPF and Silverlight technologies. She is president and owner of Zag Studio LLC. Before becoming an independent consultant, she worked at Microsoft for over five years, helping to create the Silverlight and WPF application frameworks. Her blog has a lot of helpful tips related to data binding, controls, and styles.

The WPFpedia resource guide has 37 total links to this site.


There aren't any comments yet for this resource. Be the first to add one!

Add a Comment

Please log in to post comments.



Thumbnail Screenshots by Thumbshots