How to simple fixed header and fixed column only?

How to simple fixed header and fixed column only?

junhong_cjunhong_c Posts: 2Questions: 0Answers: 0
edited August 2012 in General
Hi everybody, is there any simple code for fixed header, column and scroll only? I have turn off the sorting function but the report still running long time if the record more than 2000. So I just wanna the simple code to fixed header and column only. Thanks.

Replies

  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    The code to actually fix the top and left of the table is relatively trivial: http://datatables.net/release-datatables/extras/FixedHeader/top_bottom_left_right.html (shows all for sized fixed, just disable the bottom and right as required), but it is always going to take a long time to run if you have 2000 rows displayed.

    To have a fixed column, each and every row must have its size calculated and applied to the fixed column - that is a horribly slow thing to do, but there is really no way around it, while still having it work correctly.

    Paging is one option, and another might be FixedColumns with CSS set row height: http://datatables.net/release-datatables/extras/FixedColumns/css_size.html

    Allan
  • junhong_cjunhong_c Posts: 2Questions: 0Answers: 0
    Thanks Allan.
This discussion has been closed.