https://issues.apache.org/bugzilla/show_bug.cgi?id=54524
Bug ID: 54524
Summary: Error occurred at FormulaShifter#rowMoveAreaPtg while
shift rows upward.
Product: POI
Version: 3.9
Hardware: PC
Status: NEW
Severity: normal
Priority: P2
Component: POI Overall
Assignee: [email protected]
Reporter: [email protected]
Classification: Unclassified
Created attachment 29919
--> https://issues.apache.org/bugzilla/attachment.cgi?id=29919&action=edit
material about the problem
While shift rows upward, the reference like "A2:A3" in a formula can't be
updated normally, an error occurred instead.
Exception stacks as blew:
=============================================================================================================
Exception in thread "main" java.lang.IllegalStateException: Situation not
covered: (3, 5, -1, 1, 2)
at
org.apache.poi.ss.formula.FormulaShifter.rowMoveAreaPtg(FormulaShifter.java:331)
at
org.apache.poi.ss.formula.FormulaShifter.adjustPtgDueToRowMove(FormulaShifter.java:152)
at
org.apache.poi.ss.formula.FormulaShifter.adjustPtg(FormulaShifter.java:119)
at
org.apache.poi.ss.formula.FormulaShifter.adjustFormula(FormulaShifter.java:107)
at
org.apache.poi.xssf.usermodel.helpers.XSSFRowShifter.shiftFormula(XSSFRowShifter.java:188)
at
org.apache.poi.xssf.usermodel.helpers.XSSFRowShifter.updateRowFormulas(XSSFRowShifter.java:156)
at
org.apache.poi.xssf.usermodel.helpers.XSSFRowShifter.updateSheetFormulas(XSSFRowShifter.java:143)
at
org.apache.poi.xssf.usermodel.helpers.XSSFRowShifter.updateFormulas(XSSFRowShifter.java:130)
at org.apache.poi.xssf.usermodel.XSSFSheet.shiftRows(XSSFSheet.java:2364)
at org.apache.poi.xssf.usermodel.XSSFSheet.shiftRows(XSSFSheet.java:2306)
at Main.main(Main.java:15)
=============================================================================================================
There are two parts in the attachment uploaded.
1. A sample with a excel file(.xlsx format) and a java source.
2. A modified source(org.apache.poi.ss.formula.FormulaShifter.java) to resolve
the problem.
It will be helpful if whether the problem is truely existing and whether the
modified is OK are confirmed ASAP.
Thank you.
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]