Exemplo n.º 1
0
        public void CrawlSubCategory(List <HtmlNode> Nodes, string category)
        {
            int id = int.Parse(categoryBal.GetCategoryID(category).Obj.ToString());

            Nodes.ForEach(x =>
            {
                InsertSubCategory(HttpUtility.HtmlDecode(x.ChildNodes["a"].InnerHtml), id);
                Console.WriteLine(HttpUtility.HtmlDecode(x.ChildNodes["a"].InnerHtml));
            });

            //for (int i = 7; i < Nodes.Count; i++)
            //{
            //    InsertSubCategory(HttpUtility.HtmlDecode(Nodes[i].ChildNodes["a"].InnerHtml), id);
            //    Console.WriteLine(HttpUtility.HtmlDecode(Nodes[i].ChildNodes["a"].InnerHtml));
            //}
        }