While processing the below line, we are getting the com.aspose.cells.CellsException: Cells in range A19:D19 cannot be merged because cells in range B13:D24 have already been merged.
currentWorksheet.getCells().merge(tempRange.getFirstRow(), tempRange.getFirstColumn(), 1,noOfMergeCells);
We are getting the below value in merge.
currentWorksheet.getCells().merge(18, 0 ,1,4);
We attached the sample excel sheet which we used.