{二逼小青年的记事簿}为什么treelist不会显示子节点的文字?
<TreeView Name="treeView" DockPanel.Dock="Left" MinWidth="200" > <TreeView.ItemTemplate> <HierarchicalDataTemplate ItemsSource="{Binding cell}" DataType="{x:Type local:test1}" > <StackPanel Orientation="Horizontal" > <TextBlock VerticalAlignment="Center" Text="{Binding id}"/> <TextBlock VerticalAlignment="Center" Text="{Binding no}"/><!--需要加入这一行才会正确显示子节点 --> </StackPanel> </HierarchicalDataTemplate> </TreeView.ItemTemplate> </TreeView>