GradientColorType Property

Applies To

ChartFillFormat object.

Description

Returns the gradient color type for the specified fill. Can be one of the following MsoGradientColorType constants: msoGradientColorMixed, msoGradientOneColor, msoGradientPresetColors, or msoGradientTwoColors. Read-only Long.

Example

This example sets the fill format for the chart if its chart area has a one-color gradient fill.

With myChart.ChartArea.Fill
    If .Type = msoFillGradient Then
        If .GradientColorType = msoGradientOneColor Then
            .OneColorGradient Style:= msoGradientFromCorner, _
                Variant:= 1, Degree := 0.3
        End If
    End If
End With