You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2014/06/05 03:54:44 UTC

[Bug 56017] Shifting rows with comment result - Unreadable content error and comment deletion

https://issues.apache.org/bugzilla/show_bug.cgi?id=56017

--- Comment #5 from happyhuman <da...@gmail.com> ---
In: org.apache.poi.xssf.usermodel.XSSFSheet

I believe line:
2451            if(rownum < startRow || rownum > endRow) continue;

Should be above:
2439            if(sheetComments != null){


The exception I was getting started here:
2445                        ref = new CellReference(rownum + n, ref.getCol());

Looks as though it's trying to update the comments table with the new cell
references after the rows are shifted, but the iterator is over all rows and
the check for the shifted range is after this block. Therefore, an attempt
could be made for a negative row value. Fixed the issue for me anyway and hope
it helps.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org