Summary: | wb.getNumCellStyles() incorrect compared to wb.getCellStyleAt() | ||
---|---|---|---|
Product: | POI | Reporter: | Antti Koskimäki <antti.koskimaki> |
Component: | XSSF | Assignee: | POI Developers List <dev> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | P2 | ||
Version: | 3.7-dev | ||
Target Milestone: | --- | ||
Hardware: | All | ||
OS: | All | ||
Attachments: | patch for StylesTable to return size of correct (?) list |
Created attachment 25840 [details] patch for StylesTable to return size of correct (?) list XSSFWorkbook implementation of wb.getNumCellStyles returns incorrect value, usually just "1", while wb.getCellStyleAt() still finds all the styles (...before IndexOutOfBounds hits :) I inspected the code, and finally patched StylesTable to return size of different list, as shown in attached patch. Seems to work, although I would suggest that someone more familiar with XSSF internals checks through the code. I got quite confused about styleXfs vs. xfs...