How to set time out for http client request operation in windows phone 8.1/Windows 8.1
问题 How to set Timeout property to Windows.Web.Http.HttpClient operation. The code sample I used is below. public HttpClient httpClient; public CancellationTokenSource cts; public void SendRequest(addressUri,postrequestbody) { HttpHelper.CreateHttpClient(ref httpClient); cts = new CancellationTokenSource(); HttpRequestMessage msg = new HttpRequestMessage(new HttpMethod("POST"), new Uri(addressUri)); msg.Content = new HttpStringContent(postrequestbody); msg.Content.Headers.ContentType = new