public void SkanLink(string url) { WebClient client = new WebClient(); string html = client.DownloadString(url); // Scan links on this page HtmlTag tag; HtmlParser.HtmlParser parse = new HtmlParser.HtmlParser(html); fs = new FileStream("D:\\URL.txt", FileMode.Create, FileAccess.Write); sw = new StreamWriter(fs); while (parse.ParseNext("a", out tag)) { if (tag.Attributes.TryGetValue("href", out value)) { sw.WriteLine(value); } } sw.Close(); MessageBox.Show("File Created in D:\\URL.txt"); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)