Skip to content

FixedHeader

Reference

When displaying tables with a particularly large amount of data shown on each page, it can be useful to have the table's header and / or footer fixed to the top or bottom of the scrolling window. This lets your users quickly determine what each column refers to rather than needing to scroll back to the top of the table.

Enable the FixedHeader extension for DataTables.

.FixedHeader(true)
Or, configure it.
.FixedHeader(fh => fh.Header(true).HeaderOffset(50))

Enable / disable fixed header.

.Header(true)

Enable / disable fixed footer.

.Footer(true)

HeaderOffset

Offset the table's fixed header.

.HeaderOffset(50)
Offset the table's fixed header with function.
.HeaderOffset("functionName")

FooterOffset

Offset the table's fixed footer.

.FooterOffset(50)
Offset the table's fixed footer with function.
.FooterOffset("functionName")