Quantcast
Channel: htmlagilitypack Forum Rss Feed
Viewing all articles
Browse latest Browse all 655

New Post: Select encoding/charset on Windows Phone

$
0
0

Using HAP 1.4.6 on Windows Phone 7.0. Non-ASCII characters getting garbled. How can I set the encoding in the *Async methods? 

AutoDetectEncoding/OverrideEncoding seem not available on Windows Phone.

The page I am scraping (baseAddress) has "<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">" , but seems like HAP defaults to UTF8.               

 

HtmlWeb.LoadAsync(baseAddress, (s, args) =>
{
    if (args.Document != null)
    {
        this.Items.Add(new ItemViewModel()
        {
            string text = doc.DocumentNode.SelectSingleNode("//td[@align=\"center\"]").InnerText.Trim();

Viewing all articles
Browse latest Browse all 655

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>