-
Bug
-
Resolution: Invalid
-
Normal
-
None
-
3.8.3
-
None
-
Security Level: Jimmy
-
None
-
Sprint 6
steps to reproduce
1. run the attached program, it pastes a range with srcRange.paste(destRange); to another sheet
actual result
the custom column width and row height is not applied to the destination sheet.
workaround
static void applyRowHeight(Range source, Range destination) { for (int row = source.getRow() ; row <= source.getLastRow() ; row++){ int height = source.getSheet().getRowHeight(row); CellOperationUtil.setRowHeight(destination.toCellRange(row-source.getRow(), 0), height); } } static void applyColumnWidth(Range source, Range destination) { for (int c = source.getColumn() ; c <= source.getLastColumn() ; c++){ int widthPx = source.getSheet().getColumnWidth(c); CellOperationUtil.setColumnWidth(destination.toCellRange(0, c-source.getColumn()), widthPx); } }
- relates to
-
ZSS-717 Copy/Cut paste a column did not copy the column width over
- Closed