When I have the created workbook open and print the entire workbook the heading and footer just contain nullnullnull centered in the header and the footer.
If I make this setting on the data sheet it works for the data sheet.
Also, if I save this as PDF instead of XLS then the chart doesn't show any header or footer. The data sheet pages do.
I have attached sample program, an xls I generated using the code that shows the problem, and an image of what the print preview shows it is going to print.
The ChartDemoServlet.java file contained in the attached zip file is a modified version of the file included as an example in your release. I assumed you would be familiar with this example and would be able to use it. I will attempt to create a more concise example.
Here is a standalone java file that will just quickly generate an xlsx file with the problem where the header and footer contain the text nullnullnull for the chart sheet.
Please try this fix. And because of the fact that for chart sheet the
pagesetup is not of the sheet but of the chart, please use Chart.getPageSetup()
instead of Worksheet.getPageSetup() in your code to make the settings take
effect.