Share via


WebNavigationBarSetName Property.WebNavigationBarSetName Property

Publisher Developer ReferencePublisher Developer Reference

Returns a String that represents the name of the Web navigation bar set the specified shape is an instance of. Read-only.

Syntax

expression.WebNavigationBarSetName

expression   A variable that represents a WebNavigationBarSetName Property object.

Return Value
String

Remarks

This property is only accessible for shapes that represent an instance of a Web navigation bar set. Use the Type property of the Shape object to determine if a shape represents an instance of a Web navigation bar set.

Use the WebNavigationBarSetName property to return the name of a WebNavigationBarSet object. Multiple pages in a Web publication can each have a shape representing an instance of the same Web navigation bar set. Changes made to a WebNavigationBarSet object are reflected in all the shapes representing instances of that Web navigation bar set.

Example

The following example tests to determine which shapes on the first page of the active document represent instances of Web navigation bars. For each such shape found, the Web navigation bar it represents an instance of is set to auto update.

Visual Basic for Applications
  Sub SetWebBarsToAutoUpdate()

Dim shpLoop As Shape Dim strWebNavBarName As String

For Each shpLoop In ActiveDocument.Pages(1).Shapes If shpLoop.Type = pbWebNavigationBar Then

    strWebNavBarName = shpLoop.<strong>WebNavigationBarSetName</strong>
        With ActiveDocument.WebNavigationBarSets(strWebNavBarName)
            .AutoUpdate = True
        End With
    
End If

Next

End Sub

See Also