How to apply a custom style/template to a treeviewItem in xaml
So I have editted the TreeViewItem template, (so that I could get rid of the checkbox).
I was just wondering how I can apply this template 开发者_StackOverflowto my treeview...The Treeview is databound.
is it something like:
<TreeView>
<TreeView.ItemTemplate>
....
...
?
Thanks!
Use the ItemContainerStyle
of the TreeView
. Or apply it implicitly by having it defined in the resources with only the TargetType
set (this could be superior as the ItemContainerStyle
may only affect the root items).
精彩评论