We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

GridGroupingControl GroupDropHeader

[A much less important GridGroupingControl question that my last] Is there a way to create the GroupDropHeader as a separate control from the GridGroupingControl? I want to make my own header bar with several controls, only one of which is the GroupDropHeader. Is there a way to do this? Thanks, dan

2 Replies

AD Administrator Syncfusion Team March 28, 2004 01:20 PM

There is not simple way to move the droparea control. You can change the GridRectBounds so some of the client area is available for other controls. Maybe this will serve your purpose. Here are some code snippets that add a TextBox under the DropArea and above the grid. //in formload this.gridGroupingControl1.ShowGroupDropArea = true; this.textBox1 = new TextBox(); this.textBox1.BackColor = Color.LightGoldenrodYellow; this.gridGroupingControl1.TableControl.Controls.Add(this.textBox1); this.gridGroupingControl1.PerformLayout(); //grid.Layout event handler private void gridGroupingControl1_Layout(object sender, LayoutEventArgs e) { if(this.textBox1 != null && this.gridGroupingControl1.TableControl != null) { this.gridGroupingControl1.TableControl.ResetGridBounds(); Rectangle rect = this.gridGroupingControl1.TableControl.GridBounds; this.textBox1.Width = rect.Width; this.textBox1.Location = new Point(0,0); this.gridGroupingControl1.TableControl.GridBounds = new Rectangle(0, this.textBox1.Height + 2, rect.Width, rect.Height-this.textBox1.Height - 2); } }


AD Administrator Syncfusion Team March 28, 2004 03:56 PM

Thanks. Adding extra controls under the header won''t really help, but this isn''t all that important to my program -- just one of those little touches. So, you might consider it a low-priority feature request. (Basically, I have a pretty wide Grid and there''s no way the user is going to group by 30 things, so it''s wasted space. I was thinking of putting the GroupDropHeader on the top-right of the grid and then having other buttons/drops downs to its right to do things like let the user turn on and off the FilterBar and to bring up a popup that lets the select which columns are shown in the grid.)

Loader.
Live Chat Icon For mobile
Up arrow icon