I made following changes in web.config to get the SOAP (Request/Response) Envelope.
This will output all of the raw SOAP information to the file trace.log.
Working also for https - raw data are saved before wrapping to https envelope
<system.diagnostics>
<trace autoflush="true"/>
<sources>
<source name="System.Net" >
<listeners>
<add name="TraceFile"/>
</listeners>
</source>
<source name="System.Net.Sockets" >
<listeners>
<add name="TraceFile"/>
</listeners>
</source>
</sources>
<sharedListeners>
<add name="TraceFile" type="System.Diagnostics.TextWriterTraceListener"
initializeData="c:\a\trace.log"/>
</sharedListeners>
<switches>
<add name="System.Net" value="Verbose"/>
<add name="System.Net.Sockets" value="Verbose"/>
</switches>
</system.diagnostics>
original link: http://stackoverflow.com/questions/300674/getting-raw-soap-data-from-a-web-reference-client-running-in-asp-net