About 22,500 results
Open links in new tab
  1. c# - Best Practice for Use HttpClient - Stack Overflow

    May 11, 2016 · What about creating HttpRequestMessage for each request? And then use the SendAsync method of HttpClient. That way you can specify different credentials between …

  2. c# - How to get HttpClient to pass credentials along with the …

    Aug 31, 2012 · I get "The target principal name is incorrect" when using HttpClient with the above solution, but using WebClient with a similar setup passes the user's credentials through.

  3. c# - HttpClient in using statement - Stack Overflow

    Oct 22, 2016 · HttpClient is intended to be instantiated once and re-used throughout the life of an application. Especially in server applications, creating a new HttpClient instance for every …

  4. c# - Make Https call using HttpClient - Stack Overflow

    Mar 7, 2014 · I have been using HttpClient for making WebApi calls using C#. Seems neat & fast way compared to WebClient. However I am stuck up while making Https calls. How can I …

  5. c# - Adding Http Headers to HttpClient - Stack Overflow

    Aug 19, 2012 · To set custom headers on a request, build a request with the custom header before passing it to httpclient to send to http server. Default header is set on httpclient to send …

  6. c# - Download file with WebClient or HttpClient? - Stack Overflow

    I am trying to download file from a URL and I have to choose between WebClient and HttpClient. I have referenced this article and several other articles on the internet. Everywhere, it is …

  7. How to send a file and form data with HttpClient in C#

    How to send a file and form data with HttpClient in C# Asked 8 years, 5 months ago Modified 4 years, 7 months ago Viewed 98k times

  8. c# - Allowing Untrusted SSL Certificates with HttpClient - Stack …

    Sep 23, 2012 · I'm struggling to get my Windows 8 application to communicate with my test web API over SSL. It seems that HttpClient/HttpClientHandler does not provide and option to …

  9. c# - Send HTTP POST request in .NET - Stack Overflow

    Method A: HttpClient (Preferred) Available in: .NET Framework 4.5+, .NET Standard 1.1+, and .NET Core 1.0+. It is currently the preferred approach, and is asynchronous and high …

  10. c# - How to use HttpClient without async - Stack Overflow

    Oct 24, 2016 · 35 is there any way to use HttpClient without async/await and how can I get only string of response? HttpClient was specifically designed for asynchronous use. If you want to …