Hi,
I have just started using POI. I am calling sheet.autosizeColumn(colNum) .
My column numbers range from 0 to 8. I have made sure that the cells in the
columns are created before calling autosize and am using the default font.
But I get the following exception when this call is executed :
java.lang.ArrayIndexOutOfBoundsException: There are only 4 font records, you
asked for 700
at
org.apache.poi.hssf.model.Workbook.getFontRecordAt(Workbook.java:391)
at
org.apache.poi.hssf.usermodel.HSSFWorkbook.getFontAt(HSSFWorkbook.java:848)
at
org.apache.poi.hssf.usermodel.HSSFSheet.autoSizeColumn(HSSFSheet.java:1438)
at com........MyExcelReport.resizeColumns(MyExcelReport.java:74)
at com......MyExcelReport.createExcelReport(MyExcelReport.java:67)
......
My current data creates only two rows in the sheet ie. 18 cells in all.
Nothing adds up to the '700' mentioned in the exception description.
Could anyone give me an idea of what is possibly going wrong ?
Thanks !
--
View this message in context:
http://www.nabble.com/Exception-while-auto-sizing-the-columns-tf4657100.html#a13307449
Sent from the POI - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]