Propriedade XmlMappedRange.VerticalAlignment

Obtém ou define o alinhamento vertical da XmlMappedRange de controle.

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

Sintaxe

'Declaração
Property VerticalAlignment As Object
    Get
    Set
Object VerticalAlignment { get; set; }

Valor de propriedade

Tipo: System.Object
O alinhamento vertical da XmlMappedRange de controle.

Comentários

O alinhamento vertical retornado pode ser um dos seguintes valores:

Exemplos

O seguinte exemplo de código usa a HorizontalAlignment e VerticalAlignment Propriedades para alinhar o conteúdo de XmlMappedRange para a parte inferior direita. Este exemplo de código pressupõe que a planilha atual contém um XmlMappedRange chamado CustomerLastNameCell.

Private Sub AlignBottomRight()
    Me.CustomerLastNameCell.HorizontalAlignment = _
        Excel.XlHAlign.xlHAlignRight
    Me.CustomerLastNameCell.VerticalAlignment = _
        Excel.XlVAlign.xlVAlignBottom
    Me.CustomerLastNameCell.Value2 = "The contents " & _
        "of this cell are aligned to the bottom right."
    Me.CustomerLastNameCell.RowHeight = 100
    Me.CustomerLastNameCell.ColumnWidth = 75
End Sub
private void AlignBottomRight()
{
    this.CustomerLastNameCell.HorizontalAlignment = 
        Excel.XlHAlign.xlHAlignRight;
    this.CustomerLastNameCell.VerticalAlignment =
        Excel.XlVAlign.xlVAlignBottom;

    this.CustomerLastNameCell.Value2 = "The contents " +
        "of this cell are aligned to the bottom right.";
    this.CustomerLastNameCell.RowHeight = 100;
    this.CustomerLastNameCell.ColumnWidth = 75;
}

Segurança do .NET Framework

Consulte também

Referência

XmlMappedRange Interface

Namespace Microsoft.Office.Tools.Excel