[Bug 67778] null pointer Exception for Area3Dpxg type in ExternalReference in Formula Evaluation
https://bz.apache.org/bugzilla/show_bug.cgi?id=67778 PJ Fanning changed: What|Removed |Added Blocks||68979 CC||apache-bugzilla-sebastian@k ||aselo.de --- Comment #6 from PJ Fanning --- *** Bug 68979 has been marked as a duplicate of this bug. *** Referenced Bugs: https://bz.apache.org/bugzilla/show_bug.cgi?id=68979 [Bug 68979] NullPointerException in XSSFFormulaEvaluator with reference to missing external workbook -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org For additional commands, e-mail: dev-h...@poi.apache.org
[Bug 67778] null pointer Exception for Area3Dpxg type in ExternalReference in Formula Evaluation
https://bz.apache.org/bugzilla/show_bug.cgi?id=67778 Dominik Stadler changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |FIXED --- Comment #5 from Dominik Stadler --- Seems some checks were added here, thus closing this for now. Please report new issues if there are still some missing in latest versions of Apache POI. At least version 5.2.5 should include the changes from here. -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org For additional commands, e-mail: dev-h...@poi.apache.org
[Bug 67778] null pointer Exception for Area3Dpxg type in ExternalReference in Formula Evaluation
https://bz.apache.org/bugzilla/show_bug.cgi?id=67778 --- Comment #4 from PJ Fanning --- I added more null checks with r1913258 -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org For additional commands, e-mail: dev-h...@poi.apache.org
[Bug 67778] null pointer Exception for Area3Dpxg type in ExternalReference in Formula Evaluation
https://bz.apache.org/bugzilla/show_bug.cgi?id=67778 --- Comment #3 from wuchu --- Finally,I add addExternalWorkbook function in XSSFWorkbook.java to add ExternalWorkbook to XSSFCreationHelper.referencedWorkbooks and add some codes: formulaEvaluatorHashMap.put("test1.xlsx", WorkbookFactory.create(file).getCreationHelper().createFormulaEvaluator()); ((XSSFWorkbook)workbook).addExternalWorkbook("test1.xlsx", WorkbookFactory.create(file).getCreationHelper().createFormulaEvaluator())); then that's OK. But in BaseXSSFFormulaEvaluator.cacheExternalWorkbookCells(),there not check the row is null or cell is null .and there will throw null Exception. so there add if check: int nullRowCont = 0; for (int rowIndex = firstRow; rowIndex <= lastRow; rowIndex++) { XSSFRow row = sheet.getRow(rowIndex); int firstColumn = area3DPxg.getFirstColumn(); int lastColumn = area3DPxg.getLastColumn(); //System.out.println("+row+++:"+rowIndex+" **row**:"+row); if(null!=row) { for (int cellIndex = firstColumn; cellIndex <= lastColumn; cellIndex++) { //System.out.println("*cellIndex*:" + cellIndex); XSSFCell cell = row.getCell(cellIndex); //System.out.println("*cellvalue*:" + cell); String cellValue = ""; String cellR = ""; if (null != cell) { cellValue = cell.getRawValue(); cellR = new CellReference(cell).formatAsString(false); externalLinksTable.cacheData(sheet.getSheetName(), (long) rowIndex + 1, cellR, cellValue); } } }else { nullRowCont++; } if(nullRowCont>20){ break; } } -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org For additional commands, e-mail: dev-h...@poi.apache.org
[Bug 67778] null pointer Exception for Area3Dpxg type in ExternalReference in Formula Evaluation
https://bz.apache.org/bugzilla/show_bug.cgi?id=67778 --- Comment #2 from wuchu --- Created attachment 39152 --> https://bz.apache.org/bugzilla/attachment.cgi?id=39152=edit ExternalRefence Excel -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org For additional commands, e-mail: dev-h...@poi.apache.org
[Bug 67778] null pointer Exception for Area3Dpxg type in ExternalReference in Formula Evaluation
https://bz.apache.org/bugzilla/show_bug.cgi?id=67778 PJ Fanning changed: What|Removed |Added OS||All --- Comment #1 from PJ Fanning --- That external workbook code looks like it needs more mull checks. I added r1913045 as a preliminary change. -- You are receiving this mail because: You are the assignee for the bug. - To unsubscribe, e-mail: dev-unsubscr...@poi.apache.org For additional commands, e-mail: dev-h...@poi.apache.org