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

[Solved] Grouping templated column

1 Answer 80 Views
GridView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Amit Patel
Top achievements
Rank 1
Amit Patel asked on 28 Jan 2010, 07:02 PM

Hello,
I have a templated column on the grid everything seems to work fine, except for grouping. if i do not create template then grouping works, but not when it has template. In the example below, the second column works but not the first one. Does anyone has an idea how can templated column be grouped?

 

<

 

telerik:RadGridView x:Name="_gridViewResourceRequirement" Grid.Row="2" CanUserFreezeColumns="True" ShowGroupPanel="True" AutoGenerateColumns="False"

 

 

 

 

 

RowLoaded="_gridViewResourceRequirement_RowLoaded" SelectionChanged="_gridViewResourceRequirement_SelectionChanged"

 

 

 

 

 

CellEditEnded="_gridViewResourceRequirement_CellEditEnded" VerticalAlignment="Stretch" IsFilteringAllowed="True"

 

 

 

 

 

AutoExpandGroups="True" FrozenColumnCount="0">

 

 

 

 

 

 

<telerik:RadGridView.Columns>

 

 

 

 

 

 

<telerik:GridViewDataColumn HeaderTextAlignment="Center" Width="200" Header="Resource Name"

 

 

IsFilterable="True" IsGroupable="True">

 

 

 

<telerik:GridViewDataColumn.CellTemplate>

 

 

 

<DataTemplate>

 

 

 

 

 

 

<TextBlock x:Name="_textBlockResourceName" Text="{Binding ResourceId, Converter={StaticResource _resourceNameConverter}}"/>

 

 

 

 

 

 

</DataTemplate>

 

 

 

 

 

 

</telerik:GridViewDataColumn.CellTemplate>

 

 

 

 

 

 

<telerik:GridViewDataColumn.CellEditTemplate>

 

 

 

 

 

 

<DataTemplate>

 

 

 

 

 

 

<ComboBox x:Name="_resourceComboBox"

 

 

 

 

 

DisplayMemberPath="Name" Loaded="_resourceComboBox_Loaded"

 

 

 

 

 

DropDownOpened="_resourceComboBox_DropDownOpened"

 

 

 

 

 

DropDownClosed="_resourceComboBox_DropDownClosed"/>

 

 

 

 

 

 

</DataTemplate>

 

 

 

 

 

 

</telerik:GridViewDataColumn.CellEditTemplate>

 

 

 

 

 

 

</telerik:GridViewDataColumn>

 

 

 

 

 

 

<telerik:GridViewComboBoxColumn HeaderTextAlignment="Center" Header="Type" DataMemberBinding="{Binding TypeEnum, Mode=TwoWay}"

 

 

UniqueName="Type" IsFilterable="True"/>

 

 

 

</telerik:RadGridView.Columns>

 

 

 

 

 

 

</telerik:RadGridView>

 

1 Answer, 1 is accepted

Sort by
0
Vlad
Telerik team
answered on 29 Jan 2010, 07:11 AM
Hi,

You do not have DataMemberBinding for this column.

Kind regards,
Vlad
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Tags
GridView
Asked by
Amit Patel
Top achievements
Rank 1
Answers by
Vlad
Telerik team
Share this question
or