I have a problem while decoding SOAP Envelope. Here is my XML \[code\]<?xml version="1.0"?><env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope" xmlns:tns="http://c.com/partner/"> <env:Header>c <tns:MessageId env:mustUnderstand="true">3</tns:MessageId> </env:Header> <env:Body> <GetForkliftPositionResponse xmlns="http://www.c.com"> <ForkliftId>PC006</ForkliftId> </GetForkliftPositionResponse> </env:Body></env:Envelope>\[/code\]I use the following code to decode the body, but it always return to the namespace tns:MessageID, not to the env:body. I also would like to convert the XMLStreamReader to string for debugging issues, is it possible?\[code\] XMLInputFactory xif = XMLInputFactory.newFactory(); xif.setProperty("javax.xml.stream.isCoalescing", true); // decode entities into one string StringReader reader = new StringReader(Message); String SoapBody = ""; XMLStreamReader xsr = xif.createXMLStreamReader( reader ); xsr.nextTag(); // Advance to header tag xsr.nextTag(); // advance to envelope xsr.nextTag(); // advance to body\[/code\]