Table of Contents

TXlsCellRange Class

An Excel Cell range, 1-based.

Syntax

Namespace: FlexCel.Core

public class TXlsCellRange: ICloneable

Fields

Name Description
Bottom Last row on range.
Left First column on range.
Right Last column on range.
Top First row on range.

Constructors

Methods

Name Description
CalcTopCell Returns the minimum top and left coordinates for an array of ranges. If for example you have C7 and D5, this method will return C5
Clone Returns a copy of the original range.
Contains Returns true if the cell is inside the range.
Dec Returns a COPY of the range decremented by one.
Equals Returns true if both objects are equal.
FullRange Creates a range with all cells on the sheet (65536 rows x 256 columns in Excel 97-2003)
GetHashCode Returns the hashcode of the object.
HasCol True if the specified column is in the range
HasRow True if the specified row is in the range
Inc Returns a COPY of the range incremented by one.
Offset Creates a new range with the start at newTopRow, newLeftCol.
ToString A human-readable representation of the range.
Transpose Returns the range transposed, rows by columns.

Operators

Name Description
Equality Returns true if both objects are equal.
Note this is for backwards compatibility, this is a class and not immutable, so this method should return true if references are different. But that would break old code.
Inequality Returns true if both objects do not have the same value.
Note this is for backwards compatibility, this is a class and not immutable, so this method should return true if references are different. But that would break old code.

Properties

Name Description
CellRef Gets or sets the string that defines the 2D-range in A1 notation.
ColCount Number of columns on the range.
IsOneCell Returns true if the range has only one cell.
RowCount Number of rows on the range.