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

Grouping problem, empty value and no correctly grouping done

4 Answers 132 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
FMorales asked on 29 Oct 2014, 03:32 PM

I am having a problem with grouping feature, if a try to group by a column, the grid perform the grouping but it does not group rows with same colum value, so, it creates a gruping row for each row in the group with the same value in the grouping column.

Additionaly, no value of the grouping is shown in the grouping row, it shows "Column_name: " and nothing behing ":"

I have upload a picture where I am trying to group by "Product Version", but grid do not agrupate for example the values "" as same value, I have try with other columns and other values and I have always same result.

any help would be very appreciated.


4 Answers, 1 is accepted

Sort by
Top achievements
Rank 1
answered on 30 Oct 2014, 11:27 AM
I can not get it work, I will try to give more data about my scenary.

Control is a "DragAndDropRadGrid" acording to the example to get Drag and Drop functionality:

// RadGridBrowser
this.RadGridBrowser.ColumnChooserSortOrder = Telerik.WinControls.UI.RadSortOrder.Ascending;
this.RadGridBrowser.EnableCustomGrouping = true;
this.RadGridBrowser.EnableHotTracking = false;
this.RadGridBrowser.Location = new System.Drawing.Point(0, 0);
// RadGridBrowser
this.RadGridBrowser.MasterTemplate.AllowAddNewRow = false;
this.RadGridBrowser.MasterTemplate.AllowDeleteRow = false;
this.RadGridBrowser.MasterTemplate.AllowEditRow = false;
this.RadGridBrowser.MasterTemplate.AllowRowReorder = true;
this.RadGridBrowser.MasterTemplate.ClipboardCopyMode = Telerik.WinControls.UI.GridViewClipboardCopyMode.Disable;
this.RadGridBrowser.MasterTemplate.ClipboardPasteMode = Telerik.WinControls.UI.GridViewClipboardPasteMode.Disable;
this.RadGridBrowser.MasterTemplate.EnableCustomGrouping = true;
this.RadGridBrowser.MasterTemplate.EnableFiltering = true;
this.RadGridBrowser.MasterTemplate.MultiSelect = true;
this.RadGridBrowser.MasterTemplate.ShowGroupedColumns = true;
this.RadGridBrowser.Name = "RadGridBrowser";
this.RadGridBrowser.ReadOnly = true;
this.RadGridBrowser.Size = new System.Drawing.Size(554, 194);
this.RadGridBrowser.TabIndex = 5;
this.RadGridBrowser.Text = "dragAndDropRadGrid1";
this.RadGridBrowser.ThemeName = "VisualStudio2012Light";
this.RadGridBrowser.CellDoubleClick += new Telerik.WinControls.UI.GridViewCellEventHandler(this.RadGridBrowser_CellDoubleClick);
this.RadGridBrowser.ContextMenuOpening += new Telerik.WinControls.UI.ContextMenuOpeningEventHandler(this.RadGridBrowser_ContextMenuOpening);
this.RadGridBrowser.Click += new System.EventHandler(this.RadGridBrowser_Click);


public DragAndDropRadGrid()
            ThemeResolutionService.ApplicationThemeName = "VisualStudio2012Light";
            this.ThemeName = "VisualStudio2012Light";
            this.MultiSelect = true;
            this.EnableSorting = true;
            this.EnableCustomSorting = false;
            this.DisableRadDragDropService = false;
            //handle drag and drop events for the grid through the DragDrop service
            this.svc =
            this.svc.PreviewDragStart += svc_PreviewDragStart;
            this.svc.PreviewDragDrop += svc_PreviewDragDrop;
            this.svc.PreviewDragOver += svc_PreviewDragOver;
            //register the custom row selection behavior
            var gridBehavior = this.GridBehavior as BaseGridBehavior;
            gridBehavior.RegisterBehavior(typeof(GridViewDataRowInfo), new RowSelectionGridBehavior());

Any idea why grouping does not work properly?

Top achievements
Rank 1
answered on 30 Oct 2014, 07:00 PM
I have the same problem.
It looks like  grouping field comparator is not working properly.
In my case i am using generic list of poco objects as DataSource.
Top achievements
Rank 1
answered on 30 Oct 2014, 07:09 PM
HI Mikhail,

I have solved my problem.

1.- I have comment in the designer.cs file all field related with properties of the grid (make a copy) 
2.- After do that, designer automaticatly regeneratethe default properties values for the grid
3.- The grouping now works.

//this.RadGridBrowser.ColumnChooserSortOrder = Telerik.WinControls.UI.RadSortOrder.Ascending;
//this.RadGridBrowser.EnableCustomGrouping = true;
//this.RadGridBrowser.EnableHotTracking = false;
//this.RadGridBrowser.Location = new System.Drawing.Point(0, 0);
// RadGridBrowser
//this.RadGridBrowser.MasterTemplate.AllowAddNewRow = false;
//this.RadGridBrowser.MasterTemplate.AllowDeleteRow = false;
//this.RadGridBrowser.MasterTemplate.AllowEditRow = false;
//this.RadGridBrowser.MasterTemplate.AllowRowReorder = true;
//this.RadGridBrowser.MasterTemplate.ClipboardCopyMode = //Telerik.WinControls.UI.GridViewClipboardCopyMode.Disable;
//this.RadGridBrowser.MasterTemplate.ClipboardPasteMode = //Telerik.WinControls.UI.GridViewClipboardPasteMode.Disable;
//this.RadGridBrowser.MasterTemplate.EnableCustomGrouping = true;
//this.RadGridBrowser.MasterTemplate.EnableFiltering = true;
//this.RadGridBrowser.MasterTemplate.MultiSelect = true;
//this.RadGridBrowser.MasterTemplate.ShowGroupedColumns = true;
//this.RadGridBrowser.Name = "RadGridBrowser";
//this.RadGridBrowser.ReadOnly = true;
//this.RadGridBrowser.Size = new System.Drawing.Size(554, 194);
//this.RadGridBrowser.TabIndex = 5;
//this.RadGridBrowser.Text = "dragAndDropRadGrid1";
//this.RadGridBrowser.ThemeName = "VisualStudio2012Light";
//this.RadGridBrowser.CellDoubleClick += new //Telerik.WinControls.UI.GridViewCellEventHandler(this.RadGridBrowser_CellDoubleClick);
//this.RadGridBrowser.ContextMenuOpening += new //Telerik.WinControls.UI.ContextMenuOpeningEventHandler(this.RadGridBrowser_ContextMenuOpening);
//this.RadGridBrowser.Click += new System.EventHandler(this.RadGridBrowser_Click);

Telerik team
answered on 03 Nov 2014, 03:41 PM
Hello Francisco,

Thank you for writing.

As far as I can see you have set the EnableCustomGrouping property of RadGridView. Without handling the custom grouping events RadGridView does not know how to compare each value, that is why you get such results. You can read more about Custom Grouping here. As far as I can see, you do not need it, so leaving it to its default value - false, should be sufficient for this scenario.

I hope this helps.


Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

Asked by
Top achievements
Rank 1
Answers by
Top achievements
Rank 1
Top achievements
Rank 1
Telerik team
Share this question