name Property

Microsoft FrontPage Visual Basic

name Property

Returns or sets a String that represents the name of a bookmark in an HTML document.

expression.name

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

Remarks

Bookmarks are A elements with the name attribute and are members of the collection returned by using the anchors property. Hyperlinks are A elements with the href attribute and are members of the collection returned by using the links property.

Example

The following example inserts a bookmark into the active document.

    Dim objBookmark As FPHTMLAnchorElement

ActiveDocument.body.insertAdjacentHTML "beforeend", _
    "<a id=""newbookmark"">Bookmark</a>"
    
Set objBookmark = ActiveDocument.anchors.Item("newbookmark")

objBookmark.Name = "newBookmark"