|
|
|
@ -141,8 +141,6 @@ public class ExcelKit {
|
|
|
|
|
// 遍历工作表中的所有行
|
|
|
|
|
if (sheet == null) return array;
|
|
|
|
|
|
|
|
|
|
System.out.println("readSheet数据数量=" + sheet.getLastRowNum());
|
|
|
|
|
|
|
|
|
|
for (Row row : sheet) {
|
|
|
|
|
rowIndex++;
|
|
|
|
|
if (rowIndex <= skipRowCount) continue;//跳过指定的行数
|
|
|
|
@ -361,8 +359,8 @@ public class ExcelKit {
|
|
|
|
|
List<List<String>> data = ExcelKit.readSheet(workbook, skipRowCount);
|
|
|
|
|
is.close();
|
|
|
|
|
if (data.isEmpty()) {
|
|
|
|
|
System.out.println("第" + (chartNumber + 1) + "个图表,Sheet个数="+workbook.getNumberOfSheets()+",Sheet名称="+workbook.getSheetAt(0).getSheetName()+",数据为空,请检查表格是否为空");
|
|
|
|
|
System.exit(-1);
|
|
|
|
|
System.out.println(docPath + ",第" + (chartNumber + 1) + "个图表,存在数据外链接情况,请人为处理!");
|
|
|
|
|
// System.exit(-1);
|
|
|
|
|
}
|
|
|
|
|
return data;
|
|
|
|
|
}
|
|
|
|
@ -489,7 +487,7 @@ public class ExcelKit {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public static void ReadChart(String sourceWord) throws IOException, InvalidFormatException {
|
|
|
|
|
public static void ReadChart(String sourceWord) throws IOException, InvalidFormatException {
|
|
|
|
|
InputStream is = new FileInputStream(sourceWord);
|
|
|
|
|
ZipSecureFile.setMinInflateRatio(-1.0d);
|
|
|
|
|
XWPFDocument doc = new XWPFDocument(is);
|
|
|
|
|