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

How dyanmic to programme TreelistView instead of setting property on xml

0 Answers 14 Views
TreeListView
This is a migrated thread and some comments may be shown as answers.
Lior
Top achievements
Rank 1
Lior asked on 25 Oct 2012, 07:54 AM
Hi,
Currently we adopt the mvvm pattern. there is an issue dynamic column could not set in XAML, We've implemented a dynamic radgrid, but How should we create dynamic RadTreeListview by programme instead of set property on XAML
Currently there are defined in xaml, How we  to move this by dynamically creating column in a custom control.

Thank you in advance.

<telerik:RadTreeListView  ItemsSource="{Binding PhaseSelections, Mode=TwoWay}">
                <telerik:RadTreeListView.Columns>
                    <telerik:GridViewDataColumn DataMemberBinding="{Binding DisplayName, Mode=TwoWay}"/>
                      <telerik:GridViewDataColumn IsReadOnly="True">
                        <telerik:GridViewDataColumn.CellTemplate>
                            <telerik:HierarchicalDataTemplate>
                                <CheckBox  Command="{Binding SelectCommand, Source={StaticResource ViewModel}}" CommandParameter="{Binding}" IsChecked="{Binding InScope, Mode=TwoWay}"/>
                            </telerik:HierarchicalDataTemplate>
                        </telerik:GridViewDataColumn.CellTemplate>
                    </telerik:GridViewDataColumn>
                </telerik:RadTreeListView.Columns>
                <telerik:RadTreeListView.ChildTableDefinitions>
                    <telerik:TreeListViewTableDefinition ItemsSource="{Binding ChildProcess, Mode=TwoWay}">
                    </telerik:TreeListViewTableDefinition>
                </telerik:RadTreeListView.ChildTableDefinitions>
</telerik:RadTreeListView>

No answers yet. Maybe you can help?

Tags
TreeListView
Asked by
Lior
Top achievements
Rank 1
Share this question
or