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.
I want to change the bound columns in a databound grid while retaining the dataset. I want to be able to do this for 2 reasons.
1) i want the user to be able to add and remove columns
2) i want to change the entire set of visible columns to another subset without having to recreate the grid (lets say i show 10 out of a possible 50 and i have a combobox to decide which subset).
I have achieved this but i can actually see each column appearing and it takes a few seconds to add them.
How can I prevent this flickering. I''ve tried suspending the layout but that doesnt make a difference.
Also if i remove the columns and add new ones then i have to reset the datasource to see the data. Why is this?
---
this.SuspendLayout();
this.Model.SuspendChangeEvents();
this.GridBoundColumns.Clear();
foreach (string col in colNames) {
GridBoundColumn gbc = new GridBoundColumn();
gbc.MappingName = col;
gbc.ReadOnly = true;
this.GridBoundColumns.Add(gbc);
}
this.Model.ResumeChangeEvents();
this.ResumeLayout();
this.Refresh();