Java poi读取Excel表格中公式的计算值
switch (cell.getCellType()) { case HSSFCell.CELL_TYPE_FORMULA: //公式类型 // cell.getCellFormula(); try { value = String.valueOf(cell.getNumericCellValue()); } catch (IllegalStateException e) { value = String.valueOf(cell.getRichStringCellValue()); } break; }