I am reading an Excel file where I need to know if a certain cell contains the percentage format. I am using poi-2.5-final-20040302.jar. If you need to contact me my phone is 561-241-4180. I wish I could include the file, but I do not see a way. Here are the displays when the error occurs: Cell Type 0 style is 165 cell value 0.016 Exception caught Array index out of range: 165 Here is the source code I am using: private void displayCellFormat(HSSFCell cell, int type) { System.out.println("Cell Type " + type); try { HSSFCellStyle cs = cell.getCellStyle(); short format = cs.getDataFormat(); if (type == 0) { System.out.println("style is " + format + " cell value " + cell.getNumericCellValue()); } else { System.out.println("style is " + format + " cell value " + cell.getStringCellValue()); } String formatStr = HSSFDataFormat.getBuiltinFormat(format); System.out.println("format " + formatStr); }catch (Exception e) { System.out.println("Exception caught " + e.getMessage()); } } Thanks again. I love the name you gave the package HSSF. Dora
The version you use is way out of date. Please try again with a more recent version of POI.
Dora pointed out that she by mistake entered the wrong version number in the "Version" field. I changed it to "2.0FINAL" even though she uses 2.5 - which is not available in the bugzilla menu. Okay, so the bug is open for you HSSF guys again. Sorry for the confusion!
Dora, If you could attach the file using the "Create a new attachment" hyperlink then that would make the job alot easier. Jason
No attachment provided after such a long time. Marking as WONTFix. Jason