Calling web service from android device

自闭症网瘾萝莉.ら 提交于 2019-12-01 19:43:24

I don't think that will work, if you´ve got the phone connected to the same Wifi network than your computer you should access it this way:

http://ipofyourcomputer:5000/toi/something/

Once this works out you can try it with some of the libraries available on Android like:

OkHttp - https://github.com/square/okhttp

android-async-http - http://loopj.com/android-async-http/

Volley - https://android.googlesource.com/platform/frameworks/volley

Or if you're building a REST service you can use:

Retrofit - http://square.github.io/retrofit/

Hope it helps.

My problem solved by turning off windows firewall.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!