Compartir a través de


ChartSheet.HeightPercent (Propiedad)

Obtiene o establece el alto de un gráfico 3D como un porcentaje del ancho del objeto Microsoft.Office.Tools.Excel.ChartSheet.

Espacio de nombres:  Microsoft.Office.Tools.Excel
Ensamblados:   Microsoft.Office.Tools.Excel.v4.0.Utilities (en Microsoft.Office.Tools.Excel.v4.0.Utilities.dll)
  Microsoft.Office.Tools.Excel (en Microsoft.Office.Tools.Excel.dll)

Sintaxis

'Declaración
Property HeightPercent As Integer
int HeightPercent { get; set; }

Valor de propiedad

Tipo: System.Int32
El alto de un gráfico 3D como un porcentaje del ancho del objeto Microsoft.Office.Tools.Excel.ChartSheet (entre 5 y 500 por ciento).

Ejemplos

El ejemplo de código siguiente utiliza la propiedad HeightPercent para establecer el alto del objeto Microsoft.Office.Tools.Excel.ChartSheet actual en 50 por ciento del ancho del objeto Microsoft.Office.Tools.Excel.ChartSheet.

Private Sub AdjustHeight()
    Globals.Sheet1.Range("A1", "A5").Value2 = 22
    Globals.Sheet1.Range("B1", "B5").Value2 = 55

    Me.SetSourceData(Globals.Sheet1.Range("A1", "B5"), _
        Excel.XlRowCol.xlColumns)
    Me.ChartType = Excel.XlChartType.xl3DBarClustered
    Me.HeightPercent = 50
End Sub
private void AdjustHeight()
{
    Globals.Sheet1.Range["A1", "A5"].Value2 = 22;
    Globals.Sheet1.Range["B1", "B5"].Value2 = 55;

    this.SetSourceData(Globals.Sheet1.Range["A1", "B5"],
        Excel.XlRowCol.xlColumns);
    this.ChartType = Excel.XlChartType.xl3DBarClustered; 
    this.HeightPercent = 50;
}

Seguridad de .NET Framework

Vea también

Referencia

ChartSheet Interfaz

Microsoft.Office.Tools.Excel (Espacio de nombres)