XSSFWorkbook xSSFWorkbook = (XSSFWorkbook) WorkbookFactory.create(new File("C:\\sanjay\\InspectionFormTpl.xlsx"));
POIFSBigBlockSize b512 = POIFSConstants.SMALLER_BIG_BLOCK_SIZE_DETAILS;
int blockSize = 512;
assertEquals(blockSize, b512.getBigBlockSize());
System.out.println(" " + b512.getBigBlockSize());
System.out.println("Workbook has " + xSSFWorkbook.getNumberOfSheets() + " Sheets : ");
Sheet sheet = xSSFWorkbook.getSheetAt(0);
DataFormatter dataFormatter = new DataFormatter();
Cell recordNumb = sheet.getRow(2).getCell(8);
Cell name = sheet.getRow(5).getCell(2);
Cell date = sheet.getRow(5).getCell(7);
Cell time = sheet.getRow(5).getCell(10);
Cell tagNo = sheet.getRow(7).getCell(2);
Cell Odometer = sheet.getRow(7).getCell(6);
Cell location = sheet.getRow(8).getCell(2);
Cell inspector = sheet.getRow(8).getCell(5);
Cell org = sheet.getRow(8).getCell(9);
String recordNumber = dataFormatter.formatCellValue(date);
String Make = dataFormatter.formatCellValue(recordNumb);
System.out.println(" Cell =" + recordNumber + " " + name + " " + date + " " + time + " " + tagNo + " " + Odometer + " " + location + " " + inspector + " " + org);**strong text**
我正在使用相同版本的Poi罐子 1.poi-3.17 2.poi-OOXML-3.17 3.poi-OOXML-架构 - 3.17
我完全被困在这里,我找到了名为' POIFSBigBlockSize'但很困惑如何使用它的方法。