Propriedade XmlMappedRange.Cells

Obtém um Range que representa as células a XmlMappedRange de controle.

Namespace:  Microsoft.Office.Tools.Excel
Assembly:  Microsoft.Office.Tools.Excel (em Microsoft.Office.Tools.Excel.dll)

Sintaxe

'Declaração
ReadOnly Property Cells As Range
    Get
Range Cells { get; }

Valor de propriedade

Tipo: Microsoft.Office.Interop.Excel.Range
A Range que representa as células a XmlMappedRange de controle.

Exemplos

O seguinte exemplo de código usa a Cells propriedade para exibir o local da célula de uma XmlMappedRange. Este exemplo de código pressupõe que a planilha atual contém um XmlMappedRange chamado CustomerLastNameCell.

Private Sub DisplayCellRange()
    Dim range1 As Excel.Range = Me.CustomerLastNameCell.Cells
    MsgBox("CustomerLastNameCell is in range " & _
        range1.Address(ReferenceStyle:=Excel.XlReferenceStyle.xlA1))
End Sub
private void DisplayCellRange()
{
    Excel.Range range1 = this.CustomerLastNameCell.Cells;
    MessageBox.Show("CustomerLastNameCell is in range " +
        range1.get_Address(missing, missing, Excel.XlReferenceStyle.xlA1, 
        missing, missing));
}

Segurança do .NET Framework

Consulte também

Referência

XmlMappedRange Interface

Namespace Microsoft.Office.Tools.Excel