You are right WebClient does not support this. You can use HttpWebRequest and set the method to HEAD if you want this functionality:
System.Net.WebRequest request = System.Net.WebRequest.Create(uri);
request.Method = "HEAD";
request.GetResponse();
More Related Contents:
- How can I programmatically remove the 2 connection limit in WebClient
- Maximum concurrent requests for WebClient, HttpWebRequest, and HttpClient
- Automatically decompress gzip response via WebClient.DownloadData
- WebClient.DownloadString results in mangled characters due to encoding issues, but the browser is OK
- Converting Raw HTTP Request into HTTPWebRequest Object
- HTTP POST Returns Error: 417 “Expectation Failed.”
- WebClient vs. HttpWebRequest/HttpWebResponse
- When is an HTTP response finished?
- What is the best way to read GetResponseStream()?
- Add Expires or Cache Control Header to static content in IIS
- How to post a file via HTTP post in vb.net
- How can I force a hard refresh (ctrl+F5)?
- How to specify the port an ASP.NET Core application is hosted on?
- Is there a way to call a stored procedure with Dapper?
- Making a WinForms TextBox behave like your browser’s address bar
- Windows update caused MVC3 and MVC4 stop working
- Find all child processes of my own .NET process / find out if a given process is a child of my own?
- .NET LINQ query syntax vs method chain
- Does .NET 4 have a built-in JSON serializer/deserializer?
- System.Runtime.InteropServices.COMException (0x800A03EC)
- How to Regex search/replace only first occurrence in a string in .NET?
- When to use IComparable Vs. IComparer
- What’s the ‘correct’ way of registering/installing an Assembly to the GAC?
- .NET Console TextWriter that Understands Indent/Unindent/IndentLevel
- What does Error-code 0xc0000135 (or -1073741515 Exit-code) mean when starting a Windows app?
- Given a private key, is it possible to derive its public key?
- Retrieving work items and their linked work items in a single query using the TFS APIs
- How to wait until remote .NET debugger attached
- How does the Licenses.licx based .Net component licensing model work?
- Using SharpZipLib to unzip specific files?