The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
Hi, I am trying to resize (Column Resize in Client) columns in a grid that has button templates. If I remove the button templates from the headers it works. However, if I have button templates in the header of the grid the resize functionality does not work. Any thoughts on this? The code is as follows:
// Get a simple datatable to bind the grid with DataTable dt = GetData();
// Bind the datatabe to the Grid this.GridGroupingControl1.DataSource = dt; this.GridGroupingControl1.DataBind();
// my Button and TemplateButtonItem Button myButton = new Button(); TemplateButtonItem tbi;
// Create the button templates for the grid for (int i = 0; i < 3; i++) { myButton.ID = "Button" + i.ToString(); myButton.Text = "Button " + i.ToString(); myButton.BorderWidth = Unit.Parse("0px");
// Create the new template tbi = new TemplateButtonItem(myButton);
// Add the template to the grid this.GridGroupingControl1.TableDescriptor.Columns[i].HeaderTemplate = tbi; }
JAJanagan Syncfusion Team April 10, 2008 01:06 PM UTC
Hi David,
Thanks for posting your query to us.
I am able to reproduce the issue of no column resize when buttons are added to the header template. The issue mentioned here is suspected to be a defect and we have sent this to our development team for more analysis. We will update you once we get back from our development team.