I tried to parse a XML using JAXP DOM implementations and used getElementsByTagName() to get to a particular Node and
But the API has something like this "User data associated to the imported node is not carried over. " , But I dint even get the childNodes. Any body tried this before ? .
Alternatively , is there any way i can persist a particular Node( with node values) to a new Document ? Thanks.
That's how you do it. I don't see any code where you test the number of children in the source node, so perhaps you are mistaken about the number of children it has.
That's how you do it. I don't see any code where you test the number of children in the source node, so perhaps you are mistaken about the number of children it has.
Yup, but the documentNew.getChildNodes().item(0) returns null. I will double check it anyways. BTW user data(Node value) are not imported to new document ? because the main requirement i go with this approach is to get the Node value.Thanks Paul.