Share via


XmlMappedRange.Item Property (2007 System)

Gets a Range that represents a range at an offset to the XmlMappedRange control.

Namespace:  Microsoft.Office.Tools.Excel
Assembly:  Microsoft.Office.Tools.Excel.v9.0 (in Microsoft.Office.Tools.Excel.v9.0.dll)

Syntax

'Declaration
<BrowsableAttribute(False)> _
Public ReadOnly Property Item As XmlMappedRange._ItemType
'Usage
Dim instance As XmlMappedRange 
Dim value As XmlMappedRange._ItemType 

value = instance.Item
[BrowsableAttribute(false)]
public XmlMappedRange._ItemType Item { get; }
[BrowsableAttribute(false)]
public:
property XmlMappedRange._ItemType^ Item {
    XmlMappedRange._ItemType^ get ();
}
public function get Item () : XmlMappedRange._ItemType

Property Value

Type: Microsoft.Office.Tools.Excel.XmlMappedRange._ItemType
A Range that represents a range at an offset to the XmlMappedRange control.

Remarks

The Item property is intended to be used with the following parameters.

Parameter

Description

RowIndex

The index number of the cell you want to access, in order from left to right.

ColumnIndex

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.

If you attempt to use Item without specifying any parameters, Item will get an XmlMappedRange._ItemType object that is part of the Visual Studio Tools for Office infrastructure and is not intended to be used directly from your code.

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.

Optional Parameters

For information on optional parameters, see The Variable missing and Optional Parameters in Office Solutions.

Examples

The following code example uses the Item property to select the cell that is offset from an XmlMappedRange by three columns and three rows. This code example assumes that the current worksheet contains an XmlMappedRange named CustomerLastNameCell.

Private Sub SelectItem()
    Dim offsetCell As Excel.Range = _
        CType(Me.CustomerLastNameCell.Item(3, 3), Excel.Range)
    offsetCell.Value2 = "Offset cell." 
    offsetCell.Select()
End Sub
private void SelectItem()
{
    Excel.Range offsetCell = 
        (Excel.Range)this.CustomerLastNameCell.Item[3, 3];
    offsetCell.Value2 = "Offset cell.";
    offsetCell.Select();
}

.NET Framework Security

See Also

Reference

XmlMappedRange Class

XmlMappedRange Members

Microsoft.Office.Tools.Excel Namespace