0
我想用java讀取大型Excel文件(.xlsx)。 Apache有一個例子,如何去這個here。 所以我只是複製了整個班級,添加路徑到我的.xlsx文件,並試圖執行它,但我得到這個錯誤:實施XSSF示例時出錯
Error:(96, 69) java: cannot access org.openxmlformats.schemas.spreadsheetml.x2006.main.CTRst
class file for org.openxmlformats.schemas.spreadsheetml.x2006.main.CTRst not found
此錯誤是引發該行的方法endElement()
:
lastContents = new XSSFRichTextString(sst.getEntryAt(idx)).toString();
我用這種依賴對Maven:
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
<version>3.9</version>
</dependency>
如何解決這個問題?
你嘗試閱讀[Apache的POI常見問題解答關於這一主題(http://poi.apache.org/faq.html#faq-N10025)? – Gagravarr 2015-03-19 16:30:17