'System.Windows.Controls.UIElementCollection'的子节点不能为空。从UIElement派生的对象

时间:2010-10-10 11:44:22

标签: wpf exception uielement

我遇到了这个例外,不知道该怎么做。 我正在使用我在网上找到的TreeListView

  <tv:TreeListView x:Name="listView" ItemsSource="{Binding TreeRoot}" Margin="5"      Width="640" Height="732">

    </tv:TreeListView>

有没有人有这个例外?

1 个答案:

答案 0 :(得分:0)

我怀疑TreeRoot中的DataContext集合包含空项。