[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.IRangeProvider.Item

this Property

this[string]

Gets the IRange object that is specified by its A1-style reference.

Declaration
IRange this[string reference] { get; }
ReadOnly Default Property Item(reference As String) As IRange
Parameters
Type Name Description
string reference

The A1-style reference of the range.

Property Value
Type Description
IRange

The specified range.

Examples
IRangeProvider ranges = worksheet.Range;
IRange range = ranges["A1:B2"];
range.Value = "Ready";
object value = worksheet.Range["A1"].Value;

this[int, int]

Gets the IRange object that represents the cell at the specified row and column.

Declaration
IRange this[int row, int column] { get; }
ReadOnly Default Property Item(row As Integer, column As Integer) As IRange
Parameters
Type Name Description
int row

The zero-based row index of the cell.

int column

The zero-based column index of the cell.

Property Value
Type Description
IRange

The specified cell.

Examples
IRangeProvider ranges = worksheet.Range;
IRange cell = ranges[1, 1];
cell.Value = "B2";
object value = worksheet.Range["B2"].Value;

this[int, int, int, int]

Gets the IRange object that represents the range at the specified row and column with the specified size.

Declaration
IRange this[int row, int column, int rowCount, int columnCount] { get; }
ReadOnly Default Property Item(row As Integer, column As Integer, rowCount As Integer, columnCount As Integer) As IRange
Parameters
Type Name Description
int row

The zero-based row index of the first row in the range.

int column

The zero-based column index of the first column in the range.

int rowCount

The number of rows in the range.

int columnCount

The number of columns in the range.

Property Value
Type Description
IRange

The specified range.

Examples
IRangeProvider ranges = worksheet.Range;
IRange range = ranges[0, 0, 2, 2];
range.Value = new object[,] { { "Name", "Score" }, { "Alice", 95 } };
object value = worksheet.Range["B2"].Value;