I am having a problem with the grouping functionality of the WPF Control RadGridView. Dragging and dropping the column name to the "Drag a column header and drop it here to group by that column" area does not work. Nothing happens, no errors. The "IsGroupable" setting for each column is checked. I tried explicitly setting it in the xml, and it had no effect. The ShowGroupPanel
on the RadGridView is set. According to the documentation that is all that is needed.
Here is the XAML file.
<code>
<UserControl x:Class="VaultSolutions.ArchiveAccelerator.ManagementConsole.JobsGridView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
mc:Ignorable="d"
d:DesignHeight="300" d:DesignWidth="1313" xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"
xmlns:my="clr-namespace:VaultSolutions.ArchiveAccelerator.ManagementConsole" Loaded="UserControl_Loaded">
<UserControl.Resources>
<my:vwJobsView x:Key="ThreadCollection" />
</UserControl.Resources>
<DockPanel Height="Auto" Name="dockPanel1" Width="Auto" AllowDrop="True">
<telerik:RadGridView Name="JobsRadGridView" AutoGenerateColumns="False" Width="Auto" ItemsSource="{Binding Source= {StaticResource ResourceKey=ThreadCollection}}" EnableRowVirtualization="True" EnableColumnVirtualization="True" AllowDrop="True" Drop="JobsRadGridView_Drop">
<telerik:RadGridView.Columns>
<telerik:GridViewDataColumn Name="ThreadIdentity" DataMemberBinding="{Binding Path=ThreadIdentity}" Header="Job #" TextAlignment="Right" />
<telerik:GridViewDataColumn Name="TaskName" DataMemberBinding="{Binding Path=TaskName}" Header="Task Name"/>
<telerik:GridViewDataColumn Name="DTStarted" DataMemberBinding="{Binding Path=DTStarted}" Header="DT Started"/>
<telerik:GridViewDataColumn Name="DTStopped" DataMemberBinding="{Binding Path=DTStopped}" Header="DT Stopped"/>
<telerik:GridViewDataColumn Name="Target" DataMemberBinding="{Binding Path=Target}" Header="Target" />
<telerik:GridViewDataColumn Name="SubTarget" DataMemberBinding="{Binding Path=SubTarget}" Header="Sub Target" Width="200" />
<telerik:GridViewDataColumn Name="NumProcessed" DataMemberBinding="{Binding Path=NumProcessed}" Header="# Processed" TextAlignment="Right" />
<telerik:GridViewDataColumn Name="NumError" DataMemberBinding="{Binding Path=NumError}" Header="# Error" TextAlignment="Right" />
<telerik:GridViewDataColumn Name="EventMessage" DataMemberBinding="{Binding Path=EventMessage}" Header="Event Message" TextWrapping="Wrap" />
<telerik:GridViewDataColumn Name="JobStatus" DataMemberBinding="{Binding Path=JobStatus}" Header="Job Status"/>
<telerik:GridViewDataColumn Name="LastUpdate" DataMemberBinding="{Binding Path=LastUpdate}" Header="Last Update"/>
<telerik:GridViewDataColumn Name="Servername" DataMemberBinding="{Binding Path=Servername}" Header="Server Name"/>
</telerik:RadGridView.Columns>
</telerik:RadGridView>
</DockPanel>
</UserControl>
</code>
The "ThreadCollection" is an ObservableCollection.
Adding the following, displays the groups. They are grouped correctly. All seems to work unless you drag the group name off of the group bar, or use the close icon on the group name. The GridView will be correct, but you can not get the group back again.
<telerik:RadGridView.GroupDescriptors>
<telerik:GroupDescriptor Member="Target" />
<telerik:GroupDescriptor Member="JobStatus" />
<telerik:GroupDescriptor Member="Servername" />
</telerik:RadGridView.GroupDescriptors>
In an attempt to debug, I added event hanlders for Grouped and Grouping events. They never got called on the drag and drop to the group bar. The only time they were called is when the GroupDescripitors were in place, and then only when the groups were removed from the bar.
Using Telerik version 12.1.326.0
VisualStudio 2010
.NET 3.5
C#
Windows Server 2003 R2
Any suggestions would be appreciated.