Appends newChild as the last child of this node.
objXMLDOMNode = oXMLDOMNode.appendChild(newChild)
Object. Returns the new child node successfully appended to the list.
Note that this is equivalent to calling insertBefore(newChild, null). For complete information, see the insertBefore method.
The following VBScript example creates a new XMLDOMNode object, and then uses the appendChild method to append it to the document's list of children:
Dim xmlDoc
Dim root
Dim newNode
Set xmlDoc = CreateObject("Msxml2.DOMDocument")
xmlDoc.async = False
xmlDoc.load("c:\books.xml")
Set root = xmlDoc.documentElement
MsgBox root.xml
Set newNode = xmlDoc.createNode (1, "VIDEOS", "")
root.appendChild(newNode)
MsgBox root.xml
Applies To: XMLDOMAttribute Object | XMLDOMCDATASection Object | XMLDOMCharacterData Object | XMLDOMComment Object | DOMDocument Object | XMLDOMDocumentFragment Object | XMLDOMDocumentType Object | XMLDOMElement Object | XMLDOMEntity Object | XMLDOMEntityReference Object | XMLDOMNode Object | XMLDOMNotation Object | XMLDOMProcessingInstruction Object | XMLDOMText Object | XTLRuntime Object