Version

ReplaceActiveCellRange(String,String,Boolean) Method

Replaces the range containing the ActiveCell with the specified range and using the specified cell as the new ActiveCell.
Syntax
'Declaration
 
Public Overloads Function ReplaceActiveCellRange( _
   ByVal rangeAddress As String, _
   ByVal activeCellAddress As String, _
   Optional ByVal extendRangeForMergedCells As Boolean _
) As Boolean
public bool ReplaceActiveCellRange( 
   string rangeAddress,
   string activeCellAddress,
   bool extendRangeForMergedCells
)

Parameters

rangeAddress
The A1 address of the new range that will replace the range at index ActiveCellRangeIndex.
activeCellAddress
The A1 address of the new active cell from within that range.
extendRangeForMergedCells
True to adjust the rangeAddress such that it contains any intersecting merged cells; otherwise false to use the range as it is.

Return Value

A boolean indicating if the operation was performed.
Exceptions
ExceptionDescription
System.ArgumentExceptionThe activeCellAddress must be within the specified rangeAddress.
Requirements

Target Platforms: Windows 10, Windows 8.1, Windows 8, Windows 7, Windows Server 2012, Windows 7, 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

See Also