1
votes

I'm using xamarin to develop an android APP and need to consume a webservice provided by others.I can consume the web service successfully in a ASP.NET application but in a mono for android app I always got a exception showed "NameResolutionFailure"... I'm a beginer in mono for android, the following is the steps I try to consume a web service in a android app

Step 1: Add web reference:

enter image description here

Step 2: Consume the web service(http://www.citysupermarket.com.cn/MobileAppService.asmx)

AppService.MobileAppService service=new ServiceTest.AppService.MobileAppService();
service.CreateUser("[email protected]","123","victor");

I got a exception like this enter image description here

Can anyone provide some suggetion about this or show me some guides about how to comsue a SOAP web service in a mono for android APP? I really get stucked!

1

1 Answers

1
votes

NameResolution Failure means that

http://www.citysupermarket.com.cn/MobileAppService.asmx \

can't be reached, Can you access the url at All ?

Regarding:

How to consume a web service using mono for android

I'll say this DOC is quite clear docs.xamarin.com/guides/cross-platform/application_fundamentals/introduction_to_web_services