Trying to create a new WCF self-hosted web service to replace (and extend) an existing ASP.Net asmx web service. My expectation is that existing clients can change the URL they were using to call the old ASP.Net web service to point to the new WCF web service. When I do this, the new service works fine with new .Net 3.0 clients, but old clients get the follwing error:
The request failed with HTTP status 415: Cannot process the message because the content type 'text/xml; charset=utf-8' was not the expected type 'application/soap+xml; charset=utf-8'
How do I fix this Goal is no code changes for the client app.
Here's the config info for the WCF service running on the server:
< configuration>
< system.serviceModel>
< services>
< service name="MyNamespace.ValidationService" behaviorConfiguration="DefaultServiceBehaviors">
< endpoint contract="MyNamespace.IValidationService" binding="wsHttpBinding"/>
< endpoint contract="IMetadataExchange" binding="mexHttpBinding" address="mex" />
</ service>
</ services>
< behaviors>
< serviceBehaviors>
< behavior name="DefaultServiceBehaviors" >
< serviceMetadata httpGetEnabled="true" />
</ behavior>
</ serviceBehaviors>
</ behaviors>
</ system.serviceModel>
</ configuration>
.NET Development5
|