Removing parent from a JDOM element

A

arun.hallan

My JTree holds each an element which is saved when the JTree is created
from a DOM.

When i want to do the reverse, i could just take the rootNode of the
Tree, and then take the element that i saved in that node, as this will
contain the whole tree.

The trouble with this is that if i have added a node to the JTree, the
top nodes element won't detect this.

The problem i encounted when trying to take each element and trying to
build a DOM form this is that there is a constant error that i cannot
add a certain element to another because this element has already got a
parent.

Is there a way around this problem?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,432
Messages
2,571,681
Members
48,796
Latest member
Greg L.

Latest Threads

Top