0

I'm using HttpGet method for retrieving data from a web service in my Android app. Following is the code I'm using right now.

    String url = URLEditor.encode("http://"+Constants.strURL+"Orders.asmx/CheckWebConnection? TechCode="+username+"&TechPIN="+password); 
    HttpClient httpClient = new DefaultHttpClient(); 
    HttpGet httpGet = new HttpGet(url);  
    response = httpClient.execute(httpGet); 
    HttpEntity entity = response.getEntity(); 
    if(entity == null) return false;  
    is = entity.getContent(); 

But, HttpGet method doesn't respond properly now and I'm asked to change the method. Web service doesn't support HttpPost. How can I do the same operation using Soap? Do I need to download any library and attach to Eclipse? Please help me

1 Answers1

0

Download ksoap2. You will find lots of help with it including in stackoverflow, starting with :

How to call a .NET Webservice from Android using KSOAP2?

Community
  • 1
  • 1
mthpvg
  • 3,789
  • 3
  • 26
  • 34
  • yes, it works... I get a block of data while converting the response(SoapObject) to String. How to parse that? – Justin Aloor Aug 30 '11 at 11:47
  • The question was about connecting to a webservice, if my answer helps you mark it as an accepted answer. If you want to know how to parse a soapobject then ask another question and give details about it : what kind of webservice, show what the data looks like etc... – mthpvg Aug 30 '11 at 11:54