title: SOAP webservice used to work in XAMARIN.FORMS, but now it doesn't work on any device below Android 6.0
body: <p>Suddenly i got reports form user that a list in my app didn't show any data - It worked fine on my device. Later i found out that everything works fine and dandy on all android devices with 6.0 installed - every android version below 6.0(Marshmallow), wont get data transferred! I am at a loss - have no idea what has happened or how to fix this.... Help!</p>
  
  <p>Does anyone recognize this or have possible solution to how this can be fixed?</p>
  
  <p>In my forms app i have a portable library where i have a class handling the SOAP webservice, it is implemented like below:</p>
  
  <pre><code>public class soapwebservice
  {
  //private Uri baseUri = new Uri("uri");
  private static DataConnection _instance = null;
  private HttpClient client = null;
  
  //Contructor
  private DataConnection()
  {
      client = new HttpClient(new NativeMessageHandler());
      client.BaseAddress = baseUri;
  }
  public static DataConnection Instance { get { if (_instance == null) _instance = new DataConnection(); return _instance; } }
  
  public async Task&lt;Other.ServiceResponse&gt; RefreshRouteList()
  {
      try
      {
          var soapString = this.constructRefreshsoap();
          client.DefaultRequestHeaders.Clear();
          client.DefaultRequestHeaders.Add("SOAPAction", "https://trolderuterne.play2know.dk/GetRoutes");
          var content = new StringContent(soapString, Encoding.UTF8, "text/xml");
  
          using (var response = await client.PostAsync("/Classes/mobileServices.asmx", content))
          {
              if (response.IsSuccessStatusCode)
              {
                  var soapResponse = await response.Content.ReadAsStringAsync();
                  return JsonConvert.DeserializeObject&lt;Other.ServiceResponse&gt;(ParseSoapResponse(soapResponse));
              }
              return new ServiceResponse { Code = Codes.ServerError, Message = response.StatusCode.ToString() };
          }
      }
      catch (Exception ex)
      {
          return new ServiceResponse
          {
              Code = Codes.ServerError,
              Message = ex.Message
          };
      }
      finally
      {
      }
  }
  </code></pre>
  
  <p>The error message i get when running the app is: 
  "Error: NameResolutionFailure"</p>
  
  <p>I have now tried to consume the webservice directly in the android project instead of the PCL.</p>
  
  <p>Just to mention it i have my webservice going over a proxy, due to security. It still works on 6.0, but when i go to a simulator running 4.4 i still get error: "Error: NameResolutionFailure".</p>
  
  <p>I tried grabbing the original webservice directly from our server and I get the following error message: "Error: ConnectFailure (Network is unreachable)"</p>
  
  <p>Hopefully someone has some insight, and can tell me how to get the data i need from the webservice in devices below Android 6.0!</p>