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 restrict the set of columns that is displayed and customize the column header text. With the GDBG I would add GridBoundColumns to the collection prior to setting the DataSource and all was well. How do I achieve this with the GridGroupingControl?
ADAdministrator Syncfusion Team December 31, 2003 05:17 PM UTC
It is the TableDescriptor.Columns collection.
Here is how you can initialize it:
GridColumnDescriptor gridColumnDescriptor1 = new GridColumnDescriptor();
GridColumnDescriptor gridColumnDescriptor2 = new GridColumnDescriptor();
GridColumnDescriptor gridColumnDescriptor3 = new GridColumnDescriptor();
GridColumnDescriptor gridColumnDescriptor4 = new GridColumnDescriptor();
GridColumnDescriptor gridColumnDescriptor5 = new GridColumnDescriptor();
GridColumnDescriptor gridColumnDescriptor6 = new GridColumnDescriptor();
GridColumnDescriptor gridColumnDescriptor7 = new GridColumnDescriptor();
gridColumnDescriptor1.MappingName = "CustomerID";
gridColumnDescriptor2.MappingName = "CompanyName";
gridColumnDescriptor3.MappingName = "ContactName";
gridColumnDescriptor4.MappingName = "ContactTitle";
gridColumnDescriptor5.MappingName = "Country";
gridColumnDescriptor6.MappingName = "Phone";
gridColumnDescriptor7.MappingName = "Fax";
this.gridGroupingControl1.TableDescriptor.Columns.AddRange(new GridColumnDescriptor[] { gridColumnDescriptor1,
gridColumnDescriptor2,
gridColumnDescriptor3,
gridColumnDescriptor4,
gridColumnDescriptor5,
gridColumnDescriptor6,
gridColumnDescriptor7});
Stefan