This is a migrated thread and some comments may be shown as answers.

ContainerBindingCollection no longer working

2 Answers 85 Views
TreeListView
This is a migrated thread and some comments may be shown as answers.
Ross
Top achievements
Rank 1
Ross asked on 28 Jun 2011, 04:57 PM
The following code was working until I upgraded to the latest dlls. Now when I expand a node the section that used to display child information is blank:
<UserControl.Resources>
    <telerik:ContainerBindingCollection x:Key="RadTreeViewBindings">
        <telerik:ContainerBinding Binding="{Binding IsExpanded, Mode=TwoWay}" PropertyName="IsExpanded" />
    </telerik:ContainerBindingCollection>
</UserControl.Resources>
 
<Grid x:Name="LayoutRoot" Background="White">
    <telerikGridView:RadTreeListView x:Name="SourceDataTreeView" AutoExpandGroups="True" AutoGenerateColumns="False" IsReadOnly="True" ItemsSource="{Binding Path=Children}" RowIndicatorVisibility="Collapsed" SelectionMode="Single" ShowColumnHeaders="False" ShowGroupPanel="False" ShowInsertRow="False" telerik:ContainerBinding.ContainerBindings="{StaticResource RadTreeViewBindings}">
        <telerikGridView:RadTreeListView.ChildTableDefinitions>
            <telerikGridView:TreeListViewTableDefinition ItemsSource="{Binding Path=Children}" telerik:ContainerBinding.ContainerBindings="{StaticResource RadTreeViewBindings}"/>
        </telerikGridView:RadTreeListView.ChildTableDefinitions>
        <telerikGridView:RadTreeListView.ItemTemplate>
            <telerik:HierarchicalDataTemplate telerik:ContainerBinding.ContainerBindings="{StaticResource RadTreeViewBindings}" />
        </telerikGridView:RadTreeListView.ItemTemplate>
        <telerikGridView:RadTreeListView.RowStyle>
            <Style TargetType="GridView:GridViewRow">
                <Setter Property="f:SetterValueBindingHelper.PropertyBinding">
                    <Setter.Value>
                        <f:SetterValueBindingHelper Binding="{Binding Path=IsExpanded}" Property="IsExpanded" />
                    </Setter.Value>
                </Setter>
            </Style>
        </telerikGridView:RadTreeListView.RowStyle>
        <telerikGridView:RadTreeListView.Columns>
            <telerikGridView:GridViewDataColumn DataMemberBinding="{Binding Path=Name}" Header="Name" />
            <telerikGridView:GridViewDataColumn DataMemberBinding="{Binding Path=Value}" Header="Value" />
            <telerikGridView:GridViewDataColumn DataMemberBinding="{Binding Path=PropertyType}" Header="Type" />
        </telerikGridView:RadTreeListView.Columns>
    </telerikGridView:RadTreeListView>
</Grid>

2 Answers, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 30 Jun 2011, 06:23 AM
Hello,

 Can you post more info in which version this worked? Several months ago we changed the treelist expand/collapse logic due to performance reasons and with latest versions of RadTreeListView binding to IsExpanded is not supported. 

All the best,
Vlad
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Ross
Top achievements
Rank 1
answered on 30 Jun 2011, 02:44 PM
It worked w/ version 2010.2.924.1040.

Tags
TreeListView
Asked by
Ross
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Ross
Top achievements
Rank 1
Share this question
or