JavaScript Reference/Javascript Methods/moveToBookmark
"moveToBookmark()" Example
<source lang="javascript">
<html> <body> <script language="JavaScript"> function function1() {
var m = document.body.createTextRange(); var n = m.getBookmark(); m.findText("sample", 6, 2); m.select(); m.moveToBookmark(n); m.findText("sample"); m.select();
} </script>
This is some sample text<p> <input type="button" value="MoveToBookmark" onclick="function1();"> </body> </html> </source>
"moveToBookmark()" is applied to
<source lang="javascript">
+----------------+--------------------------------------------------------------+ | Applied_To |TextRange | +----------------+--------------------------------------------------------------+
</source>
"moveToBookmark()" Syntax, Parameters and Note
<source lang="javascript">
Note: Moves the object to a bookmark defined using the getBookmark() method. Returns true (successful) or false (failed).
Syntax:
textRangeName.moveToBookmark(param1) Parameters:
param1 Required; the name of the bookmark.</source>