Re: Calling an ASMX web service (with WSE 2.0) using SoapClient proxy
From: morten (morten_at_dk2net.dk)
Date: 07/16/04
- Next message: Stewart Bourke: "Re: signing message element by id / no namespace"
- Previous message: justin: "does WSE2.0 support SOAP 1.2?"
- In reply to: SA: "Calling an ASMX web service (with WSE 2.0) using SoapClient proxy"
- Next in thread: SA: "Re: Calling an ASMX web service (with WSE 2.0) using SoapClient proxy"
- Reply: SA: "Re: Calling an ASMX web service (with WSE 2.0) using SoapClient proxy"
- Messages sorted by: [ date ] [ thread ]
Date: Fri, 16 Jul 2004 09:25:58 +0200
Hi Sven
I've been struggeling with the same kind of problem. But only if my service
returns a DataSet, all other object that i tried works fine.
I don't know if this is a confirmed bug or a feature.
Workaround to get DataSet out off bodyobject follows here.:
SoapEnvelope resultEnvelope = this.SendRequestResponse("getData", envelope);
// extract result data.
//BUG: DataSet ds = (DataSet) envelope.GetBodyObject(typeof(DataSet)); //
Bug in the WSE 2.0 work around shown below.
DataSet ds = (DataSet) XmlSerializerCache.GetXmlSerializer(typeof(DataSet),
"http://tempuri.org/").Deserialize( new
StringReader(resultEnvelope.Body.InnerXml ));
Regards
Morten
"SA" <informatica@freemail.nl> wrote in message
news:Oq%23B$DtaEHA.3664@TK2MSFTNGP12.phx.gbl...
> Hi all:
>
> In order to have one generic proxy class on my client that can both handle
> TCP and HTTP channels, I created a class that derives from SoapClient.
>
> It can call my TCP SoapService (running as a Windows Service) fine.
>
> It can call my HTTP .asmx Web Service, but apparently, the SOAP body does
> not get deserialized. The argument to my WebMethod is Nothing. Yet, in
that
> same method calling RequestSoapContext.Current.Envelope.GetBodyObject()
> returns a valid object.
>
> If I call the same HTTP web service using a proxy that was generated by
> adding a Web Reference, it works fine (i.e. the argument to my WebMethod
is
> the object I expect it to be).
>
> Any ideas?
>
> --
>
> Sven
>
>
>
- Next message: Stewart Bourke: "Re: signing message element by id / no namespace"
- Previous message: justin: "does WSE2.0 support SOAP 1.2?"
- In reply to: SA: "Calling an ASMX web service (with WSE 2.0) using SoapClient proxy"
- Next in thread: SA: "Re: Calling an ASMX web service (with WSE 2.0) using SoapClient proxy"
- Reply: SA: "Re: Calling an ASMX web service (with WSE 2.0) using SoapClient proxy"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|