2 out of 7 rated this helpful - Rate this topic

WebClient.DownloadString Method

Downloads the specified resource as a String or a Uri.

Name Description
WebClient.DownloadString (String) Downloads the specified resource as a String.
WebClient.DownloadString (Uri) Downloads the specified resource as a Uri.
Did you find this helpful?
(1500 characters remaining)
Community Content Add
Annotations FAQ
Download string ignores response content type
There is a small bug in WebClient.DownloadString (and UploadString, and the Async versions).

These do not use the ContentType from the response when decoding the response content (bytes) to a string. They assume that the encoding is the encoding in the request.