ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

[¤À¨É] Âà´«ieª«¥ó»yªk¬°Selenium(chrome) ?

¥»©«³Ì«á¥Ñ t8899 ©ó 2022-9-23 21:01 ½s¿è

¦^´_ 2# singo1232001
¤W­±ªº°ÝÃD¤w§ä¨ìµª®×

1.§Ú¦pªG¥u­n tb("6") ªº²Ä¤TÄæ²Ä¤T¦C³o­ÓÀx¦sªº­È(¹Ï¤¤¶À¦â)ªº»yªk¬O?
2.°õ¦æ®É ÁôÂÃchromeµøµ¡ªº»yªk ??

TOP

¥»©«³Ì«á¥Ñ t8899 ©ó 2022-9-23 20:17 ½s¿è

¦^´_ 2# singo1232001
ÁÂÁ«ü¾É¡A³Ì«á­±»Ý¤£»Ý­n tb.quit ?? (¹³ie.quit)
¦pªG¥u­ntable 3 , »yªk¬O?

TOP

¦^´_ 1# t8899


Sub test()
Set driver = CreateObject("Selenium.ChromeDriver")
driver.get "https://mis.twse.com.tw/stock/group.jsp?type=fixed&ex=tse&ind=TIDX#STATISTICS"  '¦pªG¥d¦b³o¸Ì ÂsÄý¾¹¨S¶}¦¨ ­nª`·Nchromedriverª©¥»¬O§_§ó·s
Set tb = driver.findelementsbytag("table")
Cells.ClearContents
For Each Z In tb
r = Cells(Rows.Count, 1).End(3).Row + 3
Z.astable.toexcel Cells(r, 1)
Next
End Sub

TOP

        ÀR«ä¦Û¦b : ¤Ñ¤W³Ì¬ü¬O¬P¬P¡A¤H¥Í³Ì¬ü¬O·Å±¡¡C
ªð¦^¦Cªí ¤W¤@¥DÃD