Chart.DepthPercent property (Project)

Gets or sets the depth of a 3D chart as a percentage of the chart width (between 20 and 2000 percent). Read/write Long.

Syntax

expression.DepthPercent

expression A variable that represents a Chart object.

Remarks

The DepthPercent property fails on 2D charts.

Example

The following example sets the depth of the specified chart to be 50 percent of its width. The example should be run on a 3D chart.

Sub SetDepthPercent()
    Dim chartShape As Shape
    Dim reportName As String
    
    reportName = "Simple 3D chart"
    Set chartShape = ActiveProject.Reports(reportName).Shapes(1)
    
    chartShape.Chart.DepthPercent = 50
End Sub

Property value

INT

See also

Chart Object

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.