I am using a web service with this address: https://api.n11.com/ws/CityService.wsdl
The service has a method 'GetCities'. You can test it with http://wsdlbrowser.com/
The problem is when I get Cities from C#, it returns an array of 81 elements but 'cityId' and 'cityName' gets null.
Please help!
My code is shown below:
GetCitiesRequest request = new GetCitiesRequest();
CityServicePortClient port = new CityServicePortClient();
GetCitiesResponse getCitiesResponse = port.GetCities(request);
var list = getCitiesResponse.cities;
Got it!!!
Visual Studio is messing up the
Order
parameter onXmlElementAttribute
, so, in yourReferences.cs
file change the following:to
and
to
I am experiencing the same behavior.
My assumption is, that the service: https://api.n11.com/ws/CityService.wsdl is not returning a value.