Export (0) Print
Expand All
Expand Minimize

Range.Item Property 

Returns a Range object that represents a range at an offset to the specified range.

Namespace: Microsoft.Office.Interop.Excel
Assembly: Microsoft.Office.Interop.Excel (in microsoft.office.interop.excel.dll)

'Usage
Dim range1 As Range

Dim key As Object
Dim returnValue As Object
returnValue = range1.Item(key)

Dim sampleValue As Object
range1.Item(key) = sampleValue

object this[
	[In] object RowIndex, 
	[In, Optional] object ColumnIndex
] {get; set;}
public System.Object get_Item(
	/*in*/System.Object RowIndex, 
	/*in*/System.Object ColumnIndex
);
public void set_Item(
	/*in*/System.Object RowIndex, 
	/*in*/System.Object ColumnIndex
System.Object);
In JScript, you can use Indexed Properties defined by a class, but you cannot define your own.

Parameters

RowIndex

Required Object. The index number of the cell you want to access, in order from left to right, then down. Range.Item(1) returns the upper-left cell in the range; Range.Item(2) returns the cell immediately to the right of the upper-left cell.

ColumnIndex

Optional Object. A number or string that indicates the column number of the cell you want to access, starting with either 1 or "A" for the first column in the range.

The RowIndex and ColumnIndex arguments are relative offsets. In other words, specifying a RowIndex of 1 returns cells in the first row of the range, not the first row of the worksheet.


Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Development Platforms

Windows XP Home Edition, Windows XP Professional, Windows Server 2003, and Windows 2000

Target Platforms

Community Additions

ADD
Show:
© 2014 Microsoft