Webclient.DownloadString returns garbage

Y

Yuriy Galanter

Hi,

I am using Webclient's method Downloadstring to get a static file from a
Webserver by its URL. If the file is in ANSI encoding - I get the string
with no problems. If the file is Unicode or UTF-8 - only some 2 scrambled
characters are downloaded. Any idea why this is happening? If I am opening
same file using system.io.file methods from a network share - I get the file
with no problems.

Thanks,

Yuriy.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top