public class Hanzheng {
public static void main(String[] args) throws IOException {
String path="C:\\Users\\11399\\Desktop\\函证\\18-19年函证电子版整理-20210331\\18-19温州函证\\往来函证(18&19)-温州天擎-只打印3、8、9-仅国金重发.xlsx";
File file=new File(path);
FileInputStream in = new FileInputStream(file);
XSSFWorkbook wb = new XSSFWorkbook(in);
int num=wb.getNumberOfSheets();//这是sheets的个数
String name="不知道啥名字";
int begin=0;
int year=9999;
for(int sh=0;sh<num;sh++) {
Sheet sheets = wb.getSheetAt(sh);
int last=sheets.getLastRowNum();//最大的行
int column=8;//取8列
//取名字
Excel文件里面多个Sheet汇总
最新推荐文章于 2022-05-07 23:25:32 发布