[EMAIL PROTECTED] wrote: > I'm using the method hasAttributes from Node interface. but I'm > always catching an Exception "Method hasAttributes() not found in > interface org.w3c.dom.Node".
Class path issue -- it's picking up DOM Level 1 classes before DOM Level 2 (where the method hasAttributes was introduced). > dprDomParser.parse(new InputSource(new ByteArrayInputStream( > strXml.getBytes()))); This is a bad idea in general. If you already have it as a Java String, then don't go back to bytes -- just use a StringReader object. However, there may be a deeper problem here depending on how you got the strXml String reference. In other words, are you sure that it was transcoded into Unicode correctly? If not, then get ahold of the real bytes coming in (not the ones from the String object) and use the ByteArrayInputStream as before. Otherwise you could have corrupted data and/or the parser could barf because the bytes don't match the encoding specified in the XMLDecl of the XML document instance. -- Andy Clark * IBM, TRL - Japan * [EMAIL PROTECTED]