简体   繁体   中英

Getting java.lang.NoClassDefFoundError

    XSSFWorkbook workbook=new XSSFWorkbook("C:\\Users\\Ramesh\\Downloads\\selenium-2.53.1\\Excel files\\OceanRates per MonthTest cases.xlsx");

    XSSFSheet sheet= (XSSFSheet) workbook.getSheet("Sheet1");
    XSSFRow row= sheet.getRow(2);
    String val=row.getCell(1).getStringCellValue();
    System.out.println(val);

I had above program, and when trying to execute, I'm getting "Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/xmlbeans/XmlObject".

I have added Apache POI jar file in IntelliJ.

Include following jar and try.

xmlbeans-2.3.0.jar

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM