org.apache.poi.openxml4j.exceptions.OLE2NotOfficeXmlFileException: The supplied data appears to be in the OLE2 Format. You are calling the part of POI that deals with OOXML (Office Open XML) Documents. You need to call a different part of POI to process this data (eg HSSF instead of XSSF)
翻译:
org.apache.tomcat.util.http.fileupload。FileUploadBase$ sizelimitdedexception:请求org.apache.poi.openxml4j.exceptions。OLE2NotOfficeXmlFileException:提供的数据显示为OLE2格式。您正在调用处理OOXML (Office Open XML)文档的POI部分。您需要调用POI的另一部分来处理该数据(例如HSSF而不是XSSF)
创建文件的时候分清:HSSFWorkbook 或 XSSFWorkbook