javascript - Extracting Data From Webpage That Isn't In the Source Code -
i'd write macro in excel pulls data webpage below:
the problem i'm having employee information data isn't in page source when use code below (where nextpage set above url) responsetext
doesn't include data i'm looking for.
with createobject("msxml2.xmlhttp") .open "get", nextpage, false .send htm.body.innerhtml = .responsetext end
i wrong believe data contained within page's dom. can me understand how can download contents of page displayed (i.e. after javascript modifications have been applied) using vbscript?
using internetexplorer.application
com object should give access actual dom tree:
url = "http://www.richmond.com/..." set ie = createobject("internetexplorer.application") ie.visible = true ie.navigate url wscript.sleep 100 until ie.readystate = 4 set elem = ie.document.getelementbyid("...")
if doesn't work, may have resort phantomjs.
Comments
Post a Comment