Hi
I am trying to add a child element to an xml document but I think I may have the syntax wrong. Can anyone help.
' Get the Child content nodes
SET objXMLDataDoc = CreateObject("Msxml2.DOMDocument"
objXMLDataDoc.Load(istrRealPath & strValue)
SET objXMLDataRoot = objXMLDataDoc.getElementsByTagName("content".Item(0)
' Add the node
SET objCopy = objXMLDataRoot.cloneNode(TRUE)
SET objTopNode = objFieldNode.appendChild(objCopy)
<content>
<item>
<field>
i want to add new childnode here
</field>
</item>
</content>
I am trying to add a child element to an xml document but I think I may have the syntax wrong. Can anyone help.
' Get the Child content nodes
SET objXMLDataDoc = CreateObject("Msxml2.DOMDocument"
objXMLDataDoc.Load(istrRealPath & strValue)
SET objXMLDataRoot = objXMLDataDoc.getElementsByTagName("content".Item(0)
' Add the node
SET objCopy = objXMLDataRoot.cloneNode(TRUE)
SET objTopNode = objFieldNode.appendChild(objCopy)
<content>
<item>
<field>
i want to add new childnode here
</field>
</item>
</content>