HI Can I add a child node to an Element Node with a name that exists
843834Jul 9 2003 — edited Jul 10 2003HI,
Can I add a child node to an Element Node with a name that is already existing in the Element Node.
Let me explain what I need exactly.
My Existing element Node looks like this:
<form>
<name>
<FirstName></FirstName>
<LastName></LastName>
</name>
</form>
Can I add another child node with hte name 'FirstName' to the 'name' node ..?
I want to put a attribute rvsn with a value 1 for the original 'FirstName' element Node.
so the new Element Node should look like the foloowing:
<form>
<name>
<FirstName rvsn="1"></FirstName>
<FirstName></FirstName>
<LastName></LastName>
</name>
</form>
Hopefully this is valid XML !!
when I tried to use appendChild, it removed the previous node and put the new one. Thats what is the documentation also said.. I read it after I tried it :(
Anyway, ther should be another way to add a node like that.
Any hints, ideas will be of great help.
-Thanks in advance !!
Murthy