My three-line hat is giving me trouble with merged cells. I've tried various solutions, but there's always a shift in the cells.
https://i.sstatic.net/ZAj5y.jpg
I've attempted different approaches to fixing this header issue, here's an example of what I've tried:
.table-scrolGridTerminal tr:nth-child(1) {
position: sticky;
top: 0;
}
.table-scrolGridTerminal tr:nth-child(2) {
position: sticky;
top: 25px;
}
.table-scrolGridTerminal tr:nth-child(3) {
position: sticky;
top: 50px;
}
<table class="table-scrolGridTerminal" cellspacing="0" rules="all" name="GridView3" border="1" id="MainContent_GridView3" style="width:100%;border-collapse:collapse;">
<tbody>
<tr>
<th colspan="9">header</th>
</tr>
<tr style="background-color:Gray;font-weight:bold;">
<th class="centre_align" rowspan="2">№ ktk</th>
<th class="centre_align" colspan="2">arrival</th>
<th class="centre_align" rowspan="2">№ auto</th>
</tr>
<tr style="background-color:Gray;font-weight:bold;">
<th scope="col">date</th>
<th scope="col">time</th>
</tr>
<tr style="color:#333333;background-color:#F7F6F3;">
<td>5122073</td>
<td>
<span id="MainContent_GridView3_Label2_0">15.10.2019</span>
</td>
<td>
<span id="MainContent_GridView3_Label3_0">08:27:06 </span>
</td>
<td>
12548
</td>
</tr>
</tbody>
</table>