[android-developers] Re: Retrieving XML Document from web service
Add this for all the classes you're using. This will let KSoap2 know
what java classes handle the each response element.
envelope.addMapping(request.getNamespace(),
"MyDotNetClassName",
MyAndroidClass.class);
For others trying to help this is the KSoap2 toString() once KSoap2
has parsed the XML response.
Ed
On Jul 31, 9:28 am, beacon <indiantalkiedhi...@gmail.com> wrote:
> Hello Frank,
>
> This is what I am doing on the client side
>
> SoapObject request = new SoapObject(NAMESPACE, METHOD_NAME);
> request.addProperty("token",WebPage.token);
> SoapSerializationEnvelope envelope = new
> SoapSerializationEnvelope(SoapEnvelope.VER11);
> envelope.dotNet = true;
> envelope.setOutputSoapObject(request);
> HttpTransportSE androidHttpTransport = new HttpTransportSE(URL);
> androidHttpTransport.setXmlVersionTag("<?xml version=\"1.0\" encoding=
> \"UTF-8\"?>");
> androidHttpTransport.call(SOAP_ACTION, envelope);
> SoapObject result = (SoapObject) envelope.bodyIn;
> String strResult = result.toString();
>
> I am getting all the fields that I am supposed to get, but I am not
> getting it in the XML format.That's my problem.
>
> On Jul 30, 7:05 pm, Frank Weiss <fewe...@gmail.com> wrote:
>
>
>
> > I don't recognize what data format that is, but I would guess that
> > your code has an error or is not sending the right HTTP headers. What
> > client side code are you using?
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home