Results 1 to 3 of 3

Thread: Chinese Characters Website WebClient

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Oct 2007
    Posts
    544

    Chinese Characters Website WebClient

    theEnchancedWinClient.WebClient.DownloadString("http://news.sohu.com/20050601/n225789219.shtml")

    will produce garbages.

    however I already put

    WebClient.Encoding = New System.Text.UTF8Encoding

    What should I have done?

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Chinese Characters Website WebClient

    Try each of the other standard encodings and see which works. Don't create an Encoding explicitly. The System.Text.Encoding class has a property each for the standard encodings, e.g. System.Text.Encoding.UTF8.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    Oct 2007
    Posts
    544

    Re: Chinese Characters Website WebClient

    Quote Originally Posted by jmcilhinney View Post
    Try each of the other standard encodings and see which works. Don't create an Encoding explicitly. The System.Text.Encoding class has a property each for the standard encodings, e.g. System.Text.Encoding.UTF8.
    System.Text.Encoding.UTF8 doesn't work
    System.Text.Encoding.Unicode doesn't work.

    Google is silent.

    Any other answer? Anyone else tried? There has to be an easy way. Do we need to look at actual headers returned by the site?
    Last edited by teguh123; Mar 19th, 2011 at 07:58 AM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width