JavaScript Reference/Javascript Methods/createControlRange
"createControlRange()" Example
<html>
<body>
<script language="JavaScript">
function function1() {
var myControlR = document.body.createControlRange();
myControlR.add(myT);
var m = myControlR.length;
alert("There are "+ m +" elements in the controlRange collection")
}
</script>
<input id="myT" type="button" value="Click me" onclick="function1();">
</body>
</html>
"createControlRange()" is applied to
+----------------+--------------------------------------------------------------+
| Applied_To |<body> |
+----------------+--------------------------------------------------------------+
"createControlRange()" Syntax, Parameters and Note
Note:
Creates a controlRange collection.
Syntax:
document.body.createControlRange()