How to convert jsp page to excel

How to convert jsp page to excel

eddie909eddie909 Posts: 31Questions: 6Answers: 0

I am trying to convert a jsp page that contains multiple tables (4 to 5). Can this be done using DataTables?

thanks,

  • Ed

Answers

  • allanallan Posts: 63,889Questions: 1Answers: 10,530 Site admin

    The Buttons extension for DataTables can currently export only a single table per Excel file that it creates. You can certainly have multiple DataTables and multiple Excel buttons, but if you want to have a single Excel file with (for example) 5 wordksheets, you would need to use the customize callback and do some serious XML manipulation. It is possible, but it would be a fair amount of work.

    Allan

  • eddie909eddie909 Posts: 31Questions: 6Answers: 0

    If I re-factor my code to only use one table can I have different colspan and rowspan?

    thanks for all your help.

    • Ed
  • allanallan Posts: 63,889Questions: 1Answers: 10,530 Site admin

    I'm afraid I don't really understand what you would be doing with the col and row spans?

    There is no option to use colspan or rowspan in DataTables' tbody at this time.

    Allan

  • JunbaoJunbao Posts: 2Questions: 1Answers: 0

    Do you have any example files of customizing for multiple Worksheets?
    As usual, I have been handed the project with a very short time to work on it and need to see if I can deliver all the things they want.
    Thanks - Joel

  • allanallan Posts: 63,889Questions: 1Answers: 10,530 Site admin

    No sorry, that isn't something I've tried yet.

    This is where Buttons defines the worksheet that it does create. You could extend upon that. If you don't want to modify the library code, use the customize callback of the excelHtml5 button type.

    Allan

This discussion has been closed.