'Declaration Public Function Add( _ ByVal firstRow As Integer, _ ByVal firstColumn As Integer, _ ByVal lastRow As Integer, _ ByVal lastColumn As Integer _ ) As WorksheetMergedCellsRegion
public WorksheetMergedCellsRegion Add( int firstRow, int firstColumn, int lastRow, int lastColumn )
Exception | Description |
---|---|
System.InvalidOperationException | firstRow is greater than lastRow or firstColumn is greater than lastColumn. |
System.ArgumentOutOfRangeException | Any row or column indices specified are outside the valid row or column ranges. |
System.InvalidOperationException | The new merged cell region overlaps with an existing merged cell region. |
The new merged cell region will take its value from the first cell containing a value, starting at the top-left and going across then down in the region. The value of all other cells will be lost. Similarly, the new region will initialize its cell format from the first cell containing a non-default cell format.
Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2