XML DOM setEndAfter() method
Definition and usage
The setEndAfter() method ends the range after the specified node.
Syntax:
setEndAfter(refNode)
Parameter
Parameter | Description |
---|---|
refNode | a node, and the end point of the range to be set is located after the node. |
throw
If refNode is a Document, DocumentFragment, or Attr node, or refNode The root container node is not a Document, DocumentFragment, or Attr node, and the method will throw an error code of INVALID_NODE_TYPE_ERR RangeException exception.
If refNode The document owned by this method is different from the document that created the range, and the method will throw an error code of WRONG_DOCUMENT_ERR DOMException exception.
Description
This method will set the end point of the range to be immediately adjacent to the specified refNode The position of the node.