I have the SelectedItem of my TreeListView bound to a property. However, if conditions aren't met that Property will throw an exception. How do I capture that exception? Is it a Binding error? Is it a Data error? How do I trap and expose it? DataError and GiveFeedback events don't seem to give me anything to trap.
<
telerik:RadTreeListView
x:Name
=
"treeListView"
AutoGenerateColumns
=
"False"
HorizontalAlignment
=
"Stretch"
VerticalAlignment
=
"Stretch"
CanUserFreezeColumns
=
"False"
CanUserReorderColumns
=
"False"
SelectionMode
=
"Single"
Grid.Row
=
"1"
Margin
=
"5"
IsReadOnly
=
"{Binding IsReadOnly}"
ItemsSource
=
"{Binding Hierarchy, Mode=TwoWay}"
SelectedItem
=
"{Binding SelectedItem, Mode=TwoWay}"
AutoExpandItems
=
"True"
ShowGroupPanel
=
"False"
IsFilteringAllowed
=
"False"
ShowColumnHeaders
=
"False"
IsExpandedBinding
=
"{Binding IsExpanded, Mode=TwoWay}"
DataError
=
"treeListView_DataError"
GiveFeedback
=
"treeListView_GiveFeedback"
>
<
telerik:RadTreeListView.ChildTableDefinitions
>
<
telerik:TreeListViewTableDefinition
ItemsSource
=
"{Binding Children}"
/>
</
telerik:RadTreeListView.ChildTableDefinitions
>
<
telerik:RadTreeListView.Columns
>
<
telerik:GridViewDataColumn
DataMemberBinding
=
"{Binding Name, Mode=TwoWay}"
CellTemplate
=
"{StaticResource TreeNodeTemplate}"
IsReadOnly
=
"False"
Width
=
"*"
/>
<
telerik:GridViewComboBoxColumn
x:Name
=
"itemTypeColumn"
Header
=
"Item Type"
DataMemberBinding
=
"{Binding ItemTypeID, Mode=TwoWay}"
DisplayMemberPath
=
"Name"
SelectedValueMemberPath
=
"ID"
SortMemberPath
=
"Order"
SortingState
=
"Ascending"
ItemsSource
=
"{Binding TypeModel.Items, Mode=TwoWay}"
IsReadOnly
=
"True"
Width
=
"150"
/>
<
telerik:GridViewDataColumn
DataMemberBinding
=
"{Binding IsActive, Mode=TwoWay}"
Header
=
"Include"
/>
</
telerik:RadTreeListView.Columns
>
</
telerik:RadTreeListView
>