soap - SoapObject in android application -


here fragment of android application code performdownload.java

public class performdownload {

private final string namespace = "http://tempuri.org/"; private final string url = "http://10.0.2.2:4304/service1.asmx";  public string getcontacts(string username) throws ioexception, xmlpullparserexception { //  string result = null;      final string soap_action = "http://tempuri.org/getcontacts";     final string method_name = "getcontacts";      soapobject request = new soapobject(namespace, method_name); 

request.addproperty("username",username);

    soapserializationenvelope envelope = new          soapserializationenvelope(soapenvelope.ver11);     envelope.dotnet = true; // put if web service .net 1     envelope.setoutputsoapobject(request);     httptransportse androidhttptransport = new httptransportse(url);      androidhttptransport.call(soap_action, envelope);     kvmserializable response=   (kvmserializable)envelope.bodyin; 

i getting error on soapobject,soapserializationenvelope(soapenvelope.ver11); , on. why above code not accessing soap protocol.


Comments

Popular posts from this blog

php - Why I am getting the Error "Commands out of sync; you can't run this command now" -

linux - Does gcc have any options to add version info in ELF binary file? -

java - Are there any classes that implement javax.persistence.Parameter<T>? -