title: A task was canceled Xamarin Exception
body: <p>I am getting a "<strong>A task was canceled exception</strong>" in my <strong>PostAsync</strong>. What is the cause of this? How can I fix this? I research the possible cause they think it is because of a timeout. If so, how can I extend the timeout time? If not, what are the possible fix for this?</p>
  
  <pre><code>try
  {
      string url = Constants.requestUrl + "Host=" + host + "&amp;Database=" + database + "&amp;Request=Fsq6Tr";
      string contentType = "application/json";
      JObject json = new JObject
      {
          { "CAF", caf },
          { "CustomerID", retailerCode },
          { "EmployeeNumber", employeeNumber },
          { "Street", street },
          { "Barangay", barangay },
          { "Town", town },
          { "District", district },
          { "Province", province },
          { "Country", country },
          { "Landmark", landmark },
          { "Telephone1", telephone1 },
          { "Telephone2", telephone2 },
          { "Mobile", mobile },
          { "Email", email },
          { "Location", location },
          { "Date", Convert.ToDateTime(date) },
          { "StartTime", Convert.ToDateTime(startTime) },
          { "EndTime", Convert.ToDateTime(endTime) },
          { "Photo1", photo1 },
          { "Photo2", photo2 },
          { "Photo3", photo3 },
          { "Video", video },
          { "MobilePhoto1", photo1url },
          { "MobilePhoto2", photo2url },
          { "MobilePhoto3", photo3url },
          { "MobileVideo", videourl },
          { "Rekorida", rekorida },
          { "Merchandizing", merchandizing },
          { "TradeCheck", tradecheck },
          { "Others", others },
          { "OtherConcern", otherconcern },
          { "Remarks", remarks },
          { "LastSync", Convert.ToDateTime(current_datetime) },
          { "MobileUpdate", Convert.ToDateTime(current_datetime) }
     };
  
     HttpClient client = new HttpClient();
     var response = await client.PostAsync(url, new StringContent(json.ToString(), Encoding.UTF8, contentType));
  
      await DisplayAlert("Success!", "Form sent successfully!", "Got it");
     }
     catch (Exception ex)
     {
           await DisplayAlert(" Sending Error ", ex.Message, "Got it");
     }
  </code></pre>