c# - HtmlAgilityPack - how to grab <DIV> data in a large web page -


i trying grab data webpage , <div>particular class <div class="personal_info"> has 10 similar <div>s , of same class "personal_info" ( shown in html code , want extract divs of class personal_info in 10 - 15 in every webpage .

<div class="personal_info"><span class="bold">rama anand</span><br><br> mobile: 9916184586<br>rama_asset@hotmail.com<br> bangalore</div>

to needful started using html agile pack suggested 1 in stack overflow , stuck @ beginning self bcoz of lack of knowledge in htmlagilepack c# code goes

htmlagilitypack.htmldocument dochtml = new htmlagilitypack.htmldocument();         htmlagilitypack.htmlweb dochfile = new htmlweb();          dochtml = dochfile.load("http://127.0.0.1/2.html"); 

then how code further data div class "personal_info" can grabbed ... suggestion example appreciated

i can't check right now, isn't it:

var infos = info in dochtml.documentnode.selectnodes("//div[@class='personal_info']") select info;  

Comments

Popular posts from this blog

c# - SharpSVN - How to get the previous revision? -

c++ - Is it possible to compile a VST on linux? -

url - Querystring manipulation of email Address in PHP -