skip navigation
  • Product Bundles

    DevCraft

    All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:

    • NEW: Design Kits for Figma
    • Online Training
    • Document Processing Library
    • Embedded Reporting for web and desktop

    Web

    Kendo UI UI for jQuery UI for Angular UI for React UI for Vue UI for Blazor UI for ASP.NET Core UI for ASP.NET MVC UI for ASP.NET AJAX

    Mobile

    UI for .NET MAUI

    Document Management

    Telerik Document Processing

    Desktop

    UI for .NET MAUI UI for WinUI UI for WinForms UI for WPF

    Reporting

    Telerik Reporting Telerik Report Server

    Testing & Mocking

    Test Studio Test Studio Dev Edition Telerik JustMock

    CMS

    Sitefinity

    UI/UX Tools

    ThemeBuilder Design System Kit Templates and Building Blocks

    Debugging

    Fiddler Fiddler Everywhere Fiddler Classic Fiddler Everywhere Reporter FiddlerCore

    Free Tools

    VB.NET to C# Converter Testing Framework
    View all products
  • Overview
  • Demos
  • Docs & Support
  • Pricing
  • Shopping cart
    • Account Overview
    • Your Licenses
    • Downloads
    • Support Center
    • Forum Profile
    • Payment Methods
    • Edit Profile
    • Log out
  • Login
  • Contact Us
  • Try now

Class CellRange

Represents a range of cells.

Inheritance
System.Object
CellRange
Inherited Members
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Telerik.Windows.Documents.Spreadsheet.Model
Assembly: Telerik.Windows.Documents.Spreadsheet.dll

Syntax

public class CellRange

Constructors

CellRange(Int32, Int32, Int32, Int32)

Initializes a new instance of the CellRange class.

Declaration
public CellRange(int fromRowIndex, int fromColumnIndex, int toRowIndex, int toColumnIndex)
Parameters
System.Int32 fromRowIndex

Start row index.

System.Int32 fromColumnIndex

Start column index.

System.Int32 toRowIndex

End row index.

System.Int32 toColumnIndex

End column index.

CellRange(CellIndex, CellIndex)

Initializes a new instance of the CellRange class.

Declaration
public CellRange(CellIndex fromIndex, CellIndex toIndex)
Parameters
CellIndex fromIndex

Start index.

CellIndex toIndex

End index.

Fields

Empty

An empty range.

Declaration
public static readonly CellRange Empty
Field Value
CellRange

Properties

ColumnCount

Gets the column count.

Declaration
public int ColumnCount { get; }
Property Value
System.Int32

The column count.

FromIndex

Gets the start index.

Declaration
public CellIndex FromIndex { get; }
Property Value
CellIndex

The start index.

IsSingleCell

Gets a value indicating if the cell range is single cell range.

Declaration
public bool IsSingleCell { get; }
Property Value
System.Boolean

The value indicating if the cell range is single cell range.

RowCount

Gets the row count.

Declaration
public int RowCount { get; }
Property Value
System.Int32

The row count.

ToIndex

Gets the end index.

Declaration
public CellIndex ToIndex { get; }
Property Value
CellIndex

The end index.

Methods

Contains(Int32, Int32)

Determines whether the range contains the specified index.

Declaration
public bool Contains(int rowIndex, int columnIndex)
Parameters
System.Int32 rowIndex

Index of the row.

System.Int32 columnIndex

Index of the column.

Returns
System.Boolean

The value indicating whether the range contains the specified index.

Contains(CellIndex)

Determines whether the range contains the specified index.

Declaration
public bool Contains(CellIndex index)
Parameters
CellIndex index

The index.

Returns
System.Boolean

The value indicating whether the range contains the specified index.

Contains(CellRange)

Determines whether the range contains the specified cell range.

Declaration
public bool Contains(CellRange cellRange)
Parameters
CellRange cellRange

The cell range.

Returns
System.Boolean

The value indicating whether the range contains the specified range.

Equals(Object)

Determines whether the specified System.Object is equal to the current System.Object.

Declaration
public override bool Equals(object obj)
Parameters
System.Object obj

The System.Object to compare with the current System.Object.

Returns
System.Boolean

True if the specified System.Object is equal to the current System.Object; otherwise, false.

Overrides
System.Object.Equals(System.Object)

FromColumn(Int32)

Creates a cell range of the specified column.

Declaration
public static CellRange FromColumn(int columnIndex)
Parameters
System.Int32 columnIndex

Index of the column.

Returns
CellRange

The cell range of the specified column.

FromColumnRange(Int32, Int32)

Creates a cell range of a range of columns.

Declaration
public static CellRange FromColumnRange(int fromColumnIndex, int toColumnIndex)
Parameters
System.Int32 fromColumnIndex

Start column.

System.Int32 toColumnIndex

End column.

Returns
CellRange

The cell range.

FromRow(Int32)

Creates a cell range of the specified row.

Declaration
public static CellRange FromRow(int rowIndex)
Parameters
System.Int32 rowIndex

Index of the row.

Returns
CellRange

The cell range of the specified row.

FromRowRange(Int32, Int32)

Creates a cell range of a range of rows.

Declaration
public static CellRange FromRowRange(int fromRowIndex, int toRowIndex)
Parameters
System.Int32 fromRowIndex

Start row.

System.Int32 toRowIndex

End row.

Returns
CellRange

The cell range.

GetFirstColumn()

Gets the first column.

Declaration
public CellRange GetFirstColumn()
Returns
CellRange

The cell range of the first column.

GetFirstRow()

Gets the first row.

Declaration
public CellRange GetFirstRow()
Returns
CellRange

The cell range of the first row.

GetHashCode()

Serves as a hash function for a particular type.

Declaration
public override int GetHashCode()
Returns
System.Int32

A hash code for the current System.Object.

Overrides
System.Object.GetHashCode()

GetLastColumn()

Gets the last column.

Declaration
public CellRange GetLastColumn()
Returns
CellRange

The cell range of the last column.

GetLastRow()

Gets the last row.

Declaration
public CellRange GetLastRow()
Returns
CellRange

The cell range of the last row.

Intersect(CellRange)

Intersects the present instance with another cell range.

Declaration
public CellRange Intersect(CellRange other)
Parameters
CellRange other

The other cell range.

Returns
CellRange

The intersection.

IntersectsWith(CellRange)

Determines whether the present instance intersects with another cell range.

Declaration
public bool IntersectsWith(CellRange other)
Parameters
CellRange other

The other cell range.

Returns
System.Boolean

The value indicating whether the present instance intersects with another cell range.

Offset(Int32, Int32)

Creates a new cell range using the present instance and a specified offset.

Declaration
public CellRange Offset(int rowOffset, int columnOffset)
Parameters
System.Int32 rowOffset

The row offset.

System.Int32 columnOffset

The column offset.

Returns
CellRange

The created cell range.

ToString()

Returns a System.String that represents the current System.Object.

Declaration
public override string ToString()
Returns
System.String

A System.String that represents the current System.Object.

Overrides
System.Object.ToString()
Getting Started
  • Getting Started
Support Resources
  • Documentation
Community
  • Forums
  • Blogs
  • Document Processing Feedback Portal

Copyright © 2018 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.