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 have a grid connected to a collection when the collection has no element of the grid does not display the column headers, also shows the row for data entry
MAManikandan Syncfusion Team May 4, 2011 12:19 PM UTC
Hi Jose,
Thank you for using Syncfusion products.
We have checked with your requirement and found that you are trying to hide the Column Headers and AddNewRow row when the collection is empty. You can achieve your requirement by setting the Header Row height to zero and ShowAddNewRow to false as shown in the following code snippet :
Code Snippet[C#]
this.dataGrid.ShowAddNewRow = false;
this.dataGrid.ModelLoaded += new EventHandler(dataGrid_ModelLoaded);
void dataGrid_ModelLoaded(object sender, EventArgs e) { if (collec.Count == 0) { //hiding the column headers this.dataGrid.Model.RowHeights[0] = 0d; } }