why rowgroup not working for me is thead mandatory

why rowgroup not working for me is thead mandatory

Answers

  • umaeswaraumaeswara Posts: 83Questions: 16Answers: 0

    why rowgroup not working for me. in my webpage i dont have thead. is that the reason? i creaed eample like mine . https://live.datatables.net/vipifute/869/edit

  • kthorngrenkthorngren Posts: 21,443Questions: 26Answers: 4,974

    Regardless of RowGroup Datatables requires a header. You can define it directly in HTML, use Javascript code to insert into the document before initializing Datatables or use columns.title define the th required for each column. See the HTML requirements for more details.

    Kevin

  • umaeswaraumaeswara Posts: 83Questions: 16Answers: 0

    thank you Kevin,I will use columns.title. But
    is there a way to make that header invisible. I dont want header for that table. the first column has a text and second column has a number, third column has a characteristic. i want to group by characteristic. i dont want to say header for column as text and number. though i can use characteristic as column title for the third column.

  • umaeswaraumaeswara Posts: 83Questions: 16Answers: 0

    https://live.datatables.net/kawehogo/1/edit
    I made this change to add column title for each of the column, but it didnt work. what am I missing here?

  • kthorngrenkthorngren Posts: 21,443Questions: 26Answers: 4,974

    Take a look at the browser's console. You are getting this error:

    Uncaught SyntaxError: Unexpected token ':'

    You are missing the closing ] for the columnDefs option.

    is there a way to make that header invisible.

    Try hiding the header in initComplete.

    Kevin

  • umaeswaraumaeswara Posts: 83Questions: 16Answers: 0

    thanks Kevin, yes it is working now. After i added column titles.
    https://live.datatables.net/kawehogo/1/edit
    Great help. i will explore initcomplete option.
    btw, does datatables have any inbuilt function to split one table into multiple tables ?

  • umaeswaraumaeswara Posts: 83Questions: 16Answers: 0

    btw, I was trying to add a new column. but it didnt work.

    https://live.datatables.net/kawehogo/4/edit

  • kthorngrenkthorngren Posts: 21,443Questions: 26Answers: 4,974

    does datatables have any inbuilt function to split one table into multiple tables ?

    No. How do you want to split the table into multiple tables? Such as do you want to move row data from one table to another?

    I was trying to add a new column. but it didnt work.

    All the columns need to be added before initialization or with columns.title. If you want to change the number of columns after initialization then you will need to destroy the Datatable using destroy() then reinit with the new header structure.

    Kevin

Sign In or Register to comment.