html - How to use VBA for web parsing table with data-reactid -


i trying parse each element table website, however, table reference data-reactid, question how use .document.getelementsbyxxx parse each element?

'vba table data      tblnamearr = array(worksheets("sheet1").cells(2, 4), worksheets("sheet1").cells(3, 4), worksheets("sheet1").cells(4, 4), worksheets("sheet1").cells(5, 4))     tblstartrow = 6     set elemcollection = ie.document.getelementsbytagname("table")     t = 0 elemcollection.length - 1         r = 0 (elemcollection(t).rows.length - 1)             c = 0 (elemcollection(t).rows(r).cells.length - 1)                 activesheet.cells(r + tblstartrow, c + 1) = elemcollection(t).rows(r).cells(c).innertext             next c         next r          activesheet.cells(r + tblstartrow + 2, 1) = tblnamearr(t)         tblstartrow = tblstartrow + r + 4      next t 

below source code of web need parse

the link website need parse:

http://gu.qq.com/hk00001/gp/income


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -