SpreadsheetGear 2023
CellCount Property (IRange)
Example 


SpreadsheetGear Namespace > IRange Interface : CellCount Property
Returns the number of cells represented by this range.
Syntax
'Declaration
 
ReadOnly Property CellCount As System.Long
'Usage
 
Dim instance As IRange
Dim value As System.Long
 
value = instance.CellCount
System.long CellCount {get;}
Example
long numberOfCells = worksheet.Cells["A1:XFD1048576"].CellCount; // 17,179,869,184 cells
Dim numberOfCells As Long = worksheet.Cells("A1:XFD1048576").CellCount ' 17179869184 cells
Requirements

Target Platforms: 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

Reference

IRange Interface
IRange Members
RowCount Property
ColumnCount Property
AreaCount Property
Count Property