We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Aspose Java Version 7.5.0

Aspose Cells for Java Version 7.5.0 throws a null pointer when getting cells after the worksheeet is renamed.

Aspose Cells for Java Version 7.4.3 works just fine

It appears the issue is have the worksheet is renamed:

Putting debug statements in the code I have found the following:

Ver 7.5.0 Debug:
Worksheet mWorksheet = ReportWorkBook.getWorksheets().getSheetByCodeName(cworkSheetName);

System.out.println("RCSR005 WorkSheetName :" + cworkSheetName);
RCSR005 WorkSheetName :RCSR005

System.out.println(ReportWorkBook.getWorksheets().get(0).getCodeName());
Sheet1

Next statement throws null pointer:
Cells cells = mWorksheet.getCells();

Ver 7.4.3 Debug:
Worksheet mWorksheet = ReportWorkBook.getWorksheets().getSheetByCodeName(cworkSheetName);

System.out.println("RCSR005 WorkSheetName :" + cworkSheetName);
RCSR005 WorkSheetName :RCSR005

System.out.println(ReportWorkBook.getWorksheets().get(0).getCodeName());
RCSR005

Next statement works just fine:
Cells cells = mWorksheet.getCells();

The issue now is 7.5.0 does not have the worksheet name correct have being renamed.


Hi,


Thanks for providing us some details.

Please provide us your template file and sample code (runnable) here, we will check your issue soon.

Thank you.