I am calling a .NET web service from a
Java client. I have been able to successfully send
string data from the Java client to the .NET web service. When I try to process the response, I get the following error:
"Content is not allowed in prolog".
I can see the response data correctly using the TcpTunnelGui tool, but the code crashes trying to read it.
The error is thrown from the following line of code:
xmlReader.parse( new InputSource(
new StringReader( soapMsg.getContent().toString() ) ) );
This seems to imply that there's something about the
SOAP format being sent back that is a problem. My SOAP response is as follows:
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<DownloadTablesResponse xmlns="http://SLR.org/">
<DownloadTablesResult>Success</DownloadTablesResult>
</DownloadTablesResponse>
</soap:Body>
</soap:Envelope>
Any help would be appreciated.
Thanks,
Dave