【问题标题】:Using asp webservice with android将asp webservice与android一起使用
【发布时间】:2014-02-20 15:10:29
【问题描述】:

我正在尝试通过 android 访问此链接以获取 Web 服务。

但我不知道应该使用什么库或 jar 文件来执行此操作。

我用过肥皂,但不会工作

这里是链接: http://ictfox.com/demo/Hafil_Updates/Login_Check.aspx?UserLogin=Demo&Password=Demo

【问题讨论】:

  • 这不是肥皂 API。你只会得到真正的回报......
  • 您需要在研究上付出更大的努力!!!!在这里查看:chintankhetiya.wordpress.com/2013/05/27/83
  • 这个例子展示了关于 webservice 的一般信息,我需要一些方法来调用和获取 android 上的 asp webservice

标签: java android asp.net web-services api


【解决方案1】:

我认为您可以使用 DefaultHttpClient android api 发送 GET 请求,如图所示。

 HttpClient httpclient = new DefaultHttpClient();
 HttpGet request = new HttpGet();
 URI webserv = new URI(" http://ictfox.com/demo/Hafil_Updates/Login_Check.aspx?UserLogin=Demo&Password=Demo");
  request.setURI(webserv);
  HttpResponse response = httpclient.execute(request);
  String responseStr = EntityUtils.toString(response.getEntity());

【讨论】:

    【解决方案2】:

    本教程向您展示如何使用协议soap调用android应用程序网络服务

    http://android.programmerguru.com/how-to-call-asp-net-web-service-in-android/

    【讨论】:

    • 你必须解释一下你的解决方案是如何工作的。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-09-12
    • 1970-01-01
    • 1970-01-01
    • 2012-10-11
    • 2011-04-23
    • 1970-01-01
    相关资源
    最近更新 更多