Skip to content

Infragistics Community Forum / Web / Ignite UI for jQuery / iggrid fixed header not aligned with row data

iggrid fixed header not aligned with row data

New Discussion
Smitesh Shah
Smitesh Shah asked on Nov 25, 2025 10:20 AM

Hi,

I am setting height of iggrid to set fixed header with vertical scrolling, it is fixed the header, but its not aligned with row data, please refer to this snap.

Below is the code:

$(“#tblCheckInQueList”).igGrid({
primaryKey: “templateID”,
width: ‘100%’,
height: ‘170px’,
autofitLastColumn: false,
autoGenerateColumns: false,
renderCheckboxes: true,
dataSource: data,
showHeader: true,
multiSelection: {
enabled: true
},
columns: [
{ headerText: “AppTypeMapID”, headerCssClass: “”, key: “appTypeMapID”, dataType: “number”, columnCssClass: “”, hidden: true },
{ headerText: “TemplateID”, headerCssClass: “”, key: “templateID”, dataType: “number”, columnCssClass: “”, hidden: true },
{ headerText: “Select”, headerCssClass: “”, key: “select”, dataType: “bool”, columnCssClass: “”, hidden: true },
{ headerText: “Questionnaire(s)”, headerCssClass: “”, key: “questTemplate”, dataType: “string”, columnCssClass: “smd-font-color” },
{ headerText: “Portal”, key: “portal”, dataType: “boolean”, hidden: true },
{
headerText: “Portal”, key: “portal1”, dataType: “boolean”, unbound: true, columnCssClass: “text-left”,
formula: function displayStatus(data, grid) {
var ActiveStatus = null;
if (data[“portal”] == true) {
ActiveStatus = “<label class=’custom-control custom-checkbox pmd-checkbox smd-margin-bottom-none’><input type=’checkbox’ name=’CheckInQuest_” + data[“templateID”] + “‘ class=’custom-control-input’ onclick=’activeChange(this)’ id=’chkPortalQI_” + data[“templateID”] + “‘ checked=’checked’ /><span class=’custom-control-label pmd-checkbox-ripple-effect’></span></label>”;
}
else {
ActiveStatus = “<label class=’custom-control custom-checkbox pmd-checkbox smd-margin-bottom-none’><input type=’checkbox’ name=’CheckInQuest_” + data[“templateID”] + “‘ class=’custom-control-input’ onclick=’activeChange(this)’ id=’chkPortalQI_” + data[“templateID”] + “‘ /><span class=’custom-control-label pmd-checkbox-ripple-effect’></span></label>”;
}
return ActiveStatus;
}
},
{ headerText: “Clipboard”, key: “clipboard”, dataType: “boolean”, hidden: true },
{
headerText: “Clipboard”, key: “clipboard1”, dataType: “boolean”, unbound: true, columnCssClass: “text-left”,
formula: function displayStatus(data, grid) {
var ActiveStatus = null;
if (data[“clipboard”] == true) {
ActiveStatus = “<label class=’custom-control custom-checkbox pmd-checkbox smd-margin-bottom-none’><input type=’checkbox’ name=’CheckInQuest_” + data[“templateID”] + “‘ class=’custom-control-input’ onclick=’activeChange(this)’ id=’chkClipboardQI_” + data[“templateID”] + “‘ checked=’checked’ /><span class=’custom-control-label pmd-checkbox-ripple-effect’></span></label>”;
}
else {
ActiveStatus = “<label class=’custom-control custom-checkbox pmd-checkbox smd-margin-bottom-none’><input type=’checkbox’ name=’CheckInQuest_” + data[“templateID”] + “‘ class=’custom-control-input’ onclick=’activeChange(this)’ id=’chkClipboardQI_” + data[“templateID”] + “‘ /><span class=’custom-control-label pmd-checkbox-ripple-effect’></span></label>”;
}
return ActiveStatus;
}
},
{ headerText: “Both”, key: “both”, dataType: “boolean”, hidden: true },
{
headerText: “Both”, key: “both1”, dataType: “boolean”, unbound: true, columnCssClass: “text-left”,
formula: function displayStatus(data, grid) {
var ActiveStatus = null;
if (data[“both”] == true) {
ActiveStatus = “<label class=’custom-control custom-checkbox pmd-checkbox smd-margin-bottom-none’><input type=’checkbox’ name=’CheckInQuest_” + data[“templateID”] + “‘ class=’custom-control-input’ onclick=’activeChange(this)’ id=’chkBothQI_” + data[“templateID”] + “‘ checked=’checked’ /><span class=’custom-control-label pmd-checkbox-ripple-effect’></span></label>”;
}
else {
ActiveStatus = “<label class=’custom-control custom-checkbox pmd-checkbox smd-margin-bottom-none’><input type=’checkbox’ name=’CheckInQuest_” + data[“templateID”] + “‘ class=’custom-control-input’ onclick=’activeChange(this)’ id=’chkBothQI_” + data[“templateID”] + “‘ /><span class=’custom-control-label pmd-checkbox-ripple-effect’></span></label>”;
}
return ActiveStatus;
}
}
],

// Grid Settings
features: [
{
name: “RowSelectors”,
enableCheckBoxes: true,
enableRowNumbering: false,
checkBoxStateChanging: function (evt, ui) {
isFiredFromCheckboxCIQ = true;
var grid = $(“#tblCheckInQueList”).data(“igGrid”);
if (ui.newState.toLowerCase() == ‘off’) {
grid.dataSource.updateRow(parseInt(ui.rowKey), { portal: false, clipboard: false, both: false }, true);
$(ui.row[0]).find(“input[id^=’chkPortalQI’]”).prop(‘checked’, false);
$(ui.row[0]).find(“input[id^=’chkClipboardQI’]”).prop(‘checked’, false);
$(ui.row[0]).find(“input[id^=’chkBothQI’]”).prop(‘checked’, false);
}
else {
grid.dataSource.updateRow(parseInt(ui.rowKey), { both: true }, true);
$(ui.row[0]).find(“input[id^=’chkBothQI’]”).prop(‘checked’, true);
}
},
},
{
name: “Selection”,
mode: ‘row’,
persist: true,
multipleSelection: true,
activation: true,
rowSelectionChanging: function (evt, ui) {
schApptTypeIsChangesOnKeyup = true;
if (isFiredFromCheckboxCIQ) {
isFiredFromCheckboxCIQ = false;
}
else {
return false;
}
}
},
{
name: “Responsive”,
enableVerticalRendering: false,
},
{
name: “Sorting”,
type: “local”,
columnSettings: [
{
columnKey: “questTemplate”,
allowSorting: false,
},
{
columnKey: “portal1”,
allowSorting: false,
},
{
columnKey: “clipboard1”,
allowSorting: false,
},
{
columnKey: “both1”,
allowSorting: false,
}
]
},

]
});

Please help to fix this issue.

Thanks,

Sign In to post a reply

Replies

  • 0
    Deyan Kamburov
    Deyan Kamburov answered on Nov 9, 2021 8:37 PM

    It could be bootstrap or some custom styles related to the sample

    I tried it in the following fiddle. Please check it out. The headers are aligned as expected. Can you modify it and send it back with the misaligned headers?

  • You must be logged in to reply to this topic.
Discussion created by
Favorites
Replies
Created On
Last Post
Discussion created by
Smitesh Shah
Favorites
0
Replies
1
Created On
Nov 25, 2025
Last Post
4 years, 3 months ago

Suggested Discussions

Tags

Created by

Created on

Nov 25, 2025 10:20 AM

Last activity on

Feb 12, 2026 4:04 PM