Visible Property

ChDataLabel, ChLegendEntry, PivotLabel, and TitleBar objects: Returns or sets a Boolean that determines whether the specified object is visible. Set this property to False to hide the specified object. Read/write.

Sheets and Worksheets objects: Returns or sets a Variant that determines whether the specified object is visible. Set this property to False to hide the specified object. Read/write.

Window object. Returns a Boolean that indicates whether the specified window is visible. Read-only.

XlSheetVisibility

XlSheetVisibility can be one of these XlSheetVisibility constants.
xlSheetHidden
xlSheetVeryHidden
xlSheetVisible

expression.Visible

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

Example

This example displays the legend for the specified chart and hides the specified legend entry.

Sub ShowLegend()

   ChartSpace1.Charts(0).HasLegend = True
   ChartSpace1.Charts(0).Legend.LegendEntries(1).Visible = False

End Sub

Applies to | ChDataLabel Object | ChLegendEntry Object | PivotLabel Object | Sheets Collection | TitleBar Object | Window Object | Worksheet Object | Worksheets Collection Object