main
黄海 9 months ago
parent 04a27808ba
commit 39a7d8e49d

@ -2,6 +2,7 @@ package com.dsideal.base.Test;
import cn.hutool.core.io.FileUtil;
import org.apache.poi.openxml4j.exceptions.InvalidFormatException;
import org.apache.poi.openxml4j.util.ZipSecureFile;
import org.apache.poi.xssf.usermodel.XSSFCell;
import org.apache.poi.xssf.usermodel.XSSFRow;
import org.apache.poi.xssf.usermodel.XSSFSheet;
@ -35,6 +36,7 @@ public class ReadDoc {
//读取文件
String inputUrl = file.getAbsolutePath();
InputStream is = new FileInputStream(inputUrl);
ZipSecureFile.setMinInflateRatio(-1.0d);
XWPFDocument doc = new XWPFDocument(is);
//图表
List<XWPFChart> charts = doc.getCharts();

Loading…
Cancel
Save