No, I want to turn a DOM element into something DOM4J can use. The below code uses DOM to add the element to a new Document and then uses the code you sent, but I want to skip the DocumentBuilderFactory stuff listed below.
Jim Jim Brain, [EMAIL PROTECTED] "Researching tomorrow's decisions today." (319) 369-2070 (work) SYSTEMS ARCHITECT, ITS, AEGON FINANCIAL PARTNERS -----Original Message----- From: James Strachan [mailto:[EMAIL PROTECTED]] Sent: Tuesday, January 07, 2003 12:32 AM To: Brain, Jim; DOM4J Mailing List (E-mail) Subject: Re: [dom4j-user] How do I convert a DOM element tree into a DOM4J document You want to run a W3C DOM into a dom4j document? Try org.w3c.dom.Document w3cDoc = ...; DOMReader domReader = new DOMReader(); Document document = domReader.read( w3cDoc ); James ------- http://radio.weblogs.com/0112098/ ----- Original Message ----- From: "Brain, Jim" <[EMAIL PROTECTED]> To: "DOM4J Mailing List (E-mail)" <[EMAIL PROTECTED]> Sent: Friday, January 03, 2003 7:05 PM Subject: [dom4j-user] How do I convert a DOM element tree into a DOM4J document > Is there a way to do this without doing this: > > try { > DocumentBuilder builder = > DocumentBuilderFactory.newInstance().newDocumentBuilder(); > org.w3c.dom.Document doc = builder.newDocument(); > doc.appendChild(doc.importNode(el,true)); > . > . > . > > I think I tried DOMDocument.addElement(el);, but it said the methods were > not implemented. > > Jim > > > Jim Brain, [EMAIL PROTECTED] <mailto:[EMAIL PROTECTED]> > "Researching tomorrow's decisions today." > (319) 369-2070 (work) > Systems Architect, ITS, AEGON Financial Partners > > > > ------------------------------------------------------- > This sf.net email is sponsored by:ThinkGeek > Welcome to geek heaven. > http://thinkgeek.com/sf > _______________________________________________ > dom4j-user mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/dom4j-user > __________________________________________________ Do You Yahoo!? Everything you'll ever need on one web page from News and Sport to Email and Music Charts http://uk.my.yahoo.com ------------------------------------------------------- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com _______________________________________________ dom4j-user mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/dom4j-user