https://bz.apache.org/bugzilla/show_bug.cgi?id=59740

David Le Niniven <david.lenini...@amalto.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|FIXED                       |---
             Status|RESOLVED                    |REOPENED

--- Comment #7 from David Le Niniven <david.lenini...@amalto.com> ---
The shiftRows method works as expected if we shift only one row at a time, but
if we try to shift several rows in a single call, it removes all merged areas
for the shifted rows.

For instance, if we have a Xlsx document with 2 merged cells A3:B3
Assuming lastRowNum = sheet.getLastRowNum();

Executing the following code will removed this merged region : 

sheet.shiftRows(1, lastRowNum+1, -1, true, false);

Whereas the following code will keep the shift the merged region into A2:B2 

for(int currentRow = 1; currentRow <=lastRowNum+1; currentRow++) {
    sheet.shiftRows(currentRow, currentRow, -1, true, false);
}

-- 
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

Reply via email to