HasMinorGridlines property (Excel Graph)

True if the axis has minor gridlines. Only axes in the primary axis group can have gridlines. Read/write Boolean.

Syntax

expression.HasMinorGridlines

expression Required. An expression that returns one of the objects in the Applies To list.

Example

This example sets the color of the minor gridlines for the value axis.

With myChart.Axes(xlValue) 
 If .HasMinorGridlines Then 
 .MinorGridlines.Border.ColorIndex = 4 
 ' Set color to green. 
 End If 
End With

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.