akekir
akekir

Reputation: 523

web service modify return value

We have a lot of web services (.asmx files, which can be accessed for example from http://localhost/ApplicationName/VeryAncientWebService.asmx). Also we have a sad bug, and the most painless solution to fix it - modify return value.

I know about IParameterInspector for WCF - thats really powerfull thing with public void AfterCall(string operationName, object[] outputs, object returnValue, object correlationState) and etc..

So tell me, please, is it any way to implement functionality, which will allow to modify outgoing value of web service method ([WebMethod])?

Upvotes: 1

Views: 244

Answers (1)

John Saunders
John Saunders

Reputation: 161821

The only thing that ASMX has that's anything like what WCF can do is the SoapExtension mechanism.

If you go this route (as opposed to converting your existing services to WCF), then I recommend that you first implement the example SoapExtension, make it work, then little by little "morph" it into the code you need (testing at every step). SoapExtension can be tricky.

Upvotes: 1

Related Questions