Hi,
I nedd help copying values form one node to another
Help copying values from one node to another
--------------------------------------------------------------------------------
Hi,
i have two xml nodes
<values>
<value/>
<description/>
<checked>
</values>
and second one
<names>
<name/>
<namedesc/>
</names>
I am trying to copy the value and description values from nodevalues into names node, but with no luck, here is what I have so far,Any help will be greatly appreciated.
for(iCtr=0;iCtr<=NodeList.length - 1;iCtr++)
{
xmlNodeNames.selectSingleNode("//names/name["+iCtr+"]").text=xmlNode.selectSingleNode('value').text ;
}
this code only works when iCtr=0 and gives selectsingleNode error.
I am creating nodes using
var rootNode= xmNames.selectSingleNode("//Process");
nameNode=xmldom.createElement("names");
nameNode.appendChild(xmldom.createElement("name"))
nameNode.appendChild(xmldom.createElement("namedes c"))
rootNode.appendChild(nameNode);