JavaScript UI Libraries & Blazor Components Suite – Smart UI › Forums › Data Grid › Grid Header Colspan and 2 Row Header with Row Span › Reply To: Grid Header Colspan and 2 Row Header with Row Span
Hi Ronak,
If you want to customise the grid header so that it spans over two column you can do this by accessing the columnGroups property like this:
this.grid.columns = [
{label: ‘First Name’, dataField: ‘firstName’, columnGroup: ‘name’},
{ label: ‘Last Name’, dataField: ‘lastName’, columnGroup: ‘name’ },
{ label: ‘Product’, dataField: ‘productName’, columnGroup: ‘order’},
{ label: ‘Quantity’, dataField: ‘quantity’, columnGroup: ‘order’}
]
this.grid.columnGroups = [
{ label: ‘Customer Name’, align: ‘center’, name: ‘name’ },
{ label: ‘Order Detals’, align: ‘center’, name: ‘order’ }
]
Please, do not hesitate to contact us if you have any additional questions.
Best regards,
Yavor Dashev
Smart UI Team
https://www.htmlelements.com/