I've just found an article that explains how you can
customize Web Services. Here is a link for those who's
>I don't know the answer to your question. Sorry
>But I'd like to ask you a question about the
><methodnameResponse> and <methodnameResult> tags. How did
>you strip them off? I am trying to do the same thing...
>>You wouldn't do it in a normal function. This isn't the
>>though, as a webservice method response is a string (the
>soap message). I'm
>>simply querying how to dynamically modify the
>of that string
>>response, as you can do using the Soap toolkit.
>>Because .net hides much of the implementation, it also
>seems to take away
>>the functionality to be able to dynamically modify the
>response as set out
>>How will defining a struct help? That will still be one
>>response, not two...
>>> Not a direct solution, but, to get it right, how would
>you do this with a
>>> I'd define a struct and return that.
>>> > Hi,
>>> > Does anybody know how to handle different XML
>structures in WebService
>>> > responses in .NET?
>>> > What I mean by this is having two different payloads
>in the Soap body of
>>> > server response message depending on conditions in
>the method itself.
>>> > For example, if a call is successful, I would like
>the XML in the Soap
>>> > of the server's response to be:
>>> > <Result>Success</Result>
>>> > But if there was an error, I would like the response
>>> > <Error>
>>> > <UserError>somestring</UserError>
>>> > <TechnicalError>somestring</TechnicalError>
>>> > </Error>
>>> > This is simple enough with the Soap Toolkit (low-
>level API), as you
>>> > generate your own responses, but .NET does it for
>you. I have figured
>>> > how to strip the response message from the default
>>> > tags, and modify the <methodnameResult> tags to what
>I want them to be
>>> > using the ParameterStyle attribute and XmlElement,
>however this means
>>> > predefining the response XML structure.
>>> > Anyone have any ideas?
>>> > Chris