1

I wrote web method in asmx web service

List<String> GetData(int id) {...} 

and then I invoked it by SoapObject in android application when I used this code:

response = envelope.getResponse();

what is the type of response that I should define ???

Maha Mahmoud
  • 65
  • 1
  • 2
  • 5

1 Answers1

0

You can use SoapPrimitive to get Response and then you can convert it to String using toString()

SoapPrimitive yourRes = (SoapPrimitive) envelope.getResponse();

String yourStringRes = yourRes.toString();

Reference : https://stackoverflow.com/a/18030085/2398886 and getting java.io.IOException: HTTP request failed, HTTP status: 404 in ksoap2 while passing xml data to soap1.2 android

Community
  • 1
  • 1
Tarsem Singh
  • 14,139
  • 7
  • 51
  • 71