Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/dart/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java 使用Apache POI设置单元格值时出现NoSuchMethod错误_Java_Excel_Apache Poi - Fatal编程技术网

Java 使用Apache POI设置单元格值时出现NoSuchMethod错误

Java 使用Apache POI设置单元格值时出现NoSuchMethod错误,java,excel,apache-poi,Java,Excel,Apache Poi,我在cell.setCellValue(“sdjcb”)处发现以下错误:; 谁能帮忙吗 Exception in thread "main" java.lang.NoSuchMethodError: 'org.openxmlformats.schemas.officeDocument.x2006.sharedTypes.STXstring org.openxmlformats.schemas.spreadsheetml.x2006.main.CTRst.xgetT()' at

我在
cell.setCellValue(“sdjcb”)
处发现以下错误:; 谁能帮忙吗

Exception in thread "main" java.lang.NoSuchMethodError: 'org.openxmlformats.schemas.officeDocument.x2006.sharedTypes.STXstring org.openxmlformats.schemas.spreadsheetml.x2006.main.CTRst.xgetT()'
at org.apache.poi.xssf.usermodel.XSSFRichTextString.<init>(XSSFRichTextString.java:92)
at org.apache.poi.xssf.usermodel.XSSFCell.setCellType(XSSFCell.java:928)
at org.apache.poi.xssf.usermodel.XSSFCell.setCellTypeImpl(XSSFCell.java:903)[![enter image description here][1]][1]
at org.apache.poi.ss.usermodel.CellBase.setCellType(CellBase.java:57)
线程“main”java.lang.NoSuchMethodError中的异常:'org.openxmlformats.schemas.officeDocument.x2006.sharedTypes.STXstring org.openxmlformats.schemas.spreadsheetml.x2006.main.CTRst.xgetT()' 位于org.apache.poi.xssf.usermodel.XSSFRichTextString.(XSSFRichTextString.java:92) 位于org.apache.poi.xssf.usermodel.XSSFCell.setCellType(XSSFCell.java:928) 在org.apache.poi.xssf.usermodel.XSSFCell.setCellTypeImpl(XSSFCell.java:903)[![在此处输入图像描述][1][1] 位于org.apache.poi.ss.usermodel.CellBase.setCellType(CellBase.java:57)
以下是有关poi架构的正确版本和poi版本的信息:。
删除
poi-ooxml-schemas-4.1.2.jar
ooxml-schemas-1.4.jar
并添加
poi-ooxm-full

项目中的Apache poi和Java版本是什么?看起来类路径上的Apache poi jar不匹配。如何添加依赖项?如何部署它们?您的类路径上还有什么?@arch2be java 15和apache POI 5versions@Gagravarr请查找我正在使用的所有最新版本的版本列表的更新问题。有一个ooxml模式版本的信息。如果使用POI 5.0.0及更新版本,则应使用POI ooxml full jar。但是删除ooxml-schemas-1.4.jar