CopyBookmark

Syntax

CopyBookmark Bookmark1$, Bookmark2$

Remarks

Sets Bookmark2$ to the insertion point or range of text marked by Bookmark1$. You can use this statement with predefined bookmarks — such as "\ StartOfSel" and "\ EndOfSel" — to set bookmarks relative to the insertion point or selection. For more information about predefined bookmarks, see "Operators and Predefined Bookmarks" later in this part.

Example

This example selects the current section, then sets one bookmark at the start of the section and another bookmark at the end. You can use this technique to define starting points and end points between which your macro operates.


EditGoTo "\Section"
CopyBookmark "\StartOfSel", "SectionStart"
CopyBookmark "\EndOfSel", "SectionEnd"

See Also

CmpBookmarks(), EditBookmark, SetEndOfBookmark, SetStartOfBookmark