NanoXLSX Library Documentation
![]() | WorksheetMergeCells Method (CellAddress, CellAddress) |
Merges the defined cell range
Namespace: NanoXLSX
Assembly: NanoXLSX (in NanoXLSX.dll) Version: 1.2.3.0 (1.2.3)

C#
public string MergeCells( CellAddress startAddress, CellAddress endAddress )
Parameters
- startAddress
- Type: NanoXLSXCellAddress
Start address of the merged cell range - endAddress
- Type: NanoXLSXCellAddress
End address of the merged cell range
Return Value
Type: StringReturns the validated range of the merged cells (e.g. 'A1:B12')

Exception | Condition |
---|---|
RangeException | Throws an RangeException if one of the passed cell addresses is out of range |
