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

[µo°Ý] ¦p¦ó±Nºô­¶¸ê®Æ¦Û¶K¶K©óexcelªí®æ¤W

[µo°Ý] ¦p¦ó±Nºô­¶¸ê®Æ¦Û¶K¶K©óexcelªí®æ¤W

¤j®a¦n
§Ú¦p¦ó¥i¥H±Nºô­¶¸ê®Æ¦Û°Ê¶K©óexcel©O
ºô­¶¦p¤U
http://norway.twsthr.info/StockHolders.aspx?stock=2454
§Ú§Æ±æ¥i¥H©óEXCELªºA1Äæ¦ì¶ñ¤W2454
µM«á«ö°õ¦æ
§Y¥i¦Û°Ê±Nºô­¶¸ê®Æ¶K©óexcel©O

¥»©«³Ì«á¥Ñ Airman ©ó 2015-11-7 20:02 ½s¿è

¥ý¬Ý¬Ý­ã¤jªº¬ÛÃö¤å³¹~
http://blog.xuite.net/smile1000mile/blog/210628980
http://blog.xuite.net/smile1000mile/blog?st=c&p=1&w=3375724

TOP

¦^´_ 1# hsueh0926
¸Õ¸Õ¬Ý
  1. Option Explicit
  2. Sub Ex() '¤èªk¤@ ¯Â¤å¦r
  3.     Dim Sh As Worksheet, i As Integer, k As Integer, R As Variant
  4.     With CreateObject("InternetExplorer.Application")
  5.         .Visible = True
  6.         .Navigate "http://norway.twsthr.info/StockHolders.aspx?stock=2454"
  7.         '¸ê®Æ¦b .Document.all.Tags("table")(9)
  8.         Set Sh = ActiveSheet
  9.         Sh.UsedRange.Clear
  10.         Application.StatusBar = "µ¥­Ôºô­¶¤¤..."
  11.         Do While .Busy Or .readyState <> 4: DoEvents: Loop
  12.          Application.StatusBar = "ºô­¶¤U¸ü§¹²¦...."
  13.          Application.ScreenUpdating = False        
  14.         For Each R In .Document.all.Tags("table")(9).Rows        
  15.             k = k + 1
  16.             For i = 0 To R.Cells.Length - 1
  17.                 Sh.Cells(k, i + 1) = R.Cells(i).innerText
  18.             Next
  19.         Next
  20.         Sh.UsedRange.SpecialCells(xlCellTypeBlanks).Delete
  21.         Application.ScreenUpdating = True
  22.        .Quit
  23.     End With
  24. End Sub
½Æ»s¥N½X
  1. Sub Ex2() '¤èªk¤G ºô­¶®æ¦¡
  2.     With CreateObject("InternetExplorer.Application")
  3.        ' .Visible = True
  4.         .Navigate "http://norway.twsthr.info/StockHolders.aspx?stock=2454"
  5.         Application.StatusBar = "µ¥­Ôºô­¶¤¤..."
  6.         Do While .Busy Or .readyState <> 4: DoEvents: Loop
  7.         Application.ScreenUpdating = False
  8.         Ep .Document.all.Tags("table")(9).outerHTML
  9.         Application.StatusBar = "ºô­¶¤U¸ü§¹²¦...."
  10.         Application.ScreenUpdating = True
  11.        .Quit
  12.     End With
  13. End Sub
  14. Sub Ep(S As String)
  15.     Dim Sh As Worksheet
  16.     With CreateObject("InternetExplorer.Application")
  17.         .Navigate "about:Tabs"
  18.        ' .Visible = True
  19.         .Document.body.innerHTML = S
  20.         .ExecWB 17, 2       '  Select All
  21.         .ExecWB 12, 2       '  Copy selection
  22.         Set Sh = ActiveSheet
  23.         With Sh
  24.             .Range("A1").Select
  25.             .PasteSpecial Format:="HTML", Link:=False, DisplayAsIcon:=False, NoHTMLFormatting:=False
  26.         End With
  27.         .Quit
  28.     End With
  29. End Sub
½Æ»s¥N½X
·P®¦ªº¤ß......(¦b³Â»¶®a±Ú°Q½×°Ï.¥Î¤ß¾Ç²ß·|¦³¶i¨Bªº)
¦ý¸ê·½µL­­,«á´©¦³­­,  ¤@¤Ñ1¤¸ªºÃÙ§U,¤H¤H¦³¯à¤O.

TOP

¦^´_ 3# GBKEE

¶]¥Xªº¼Æ­È¦ü¥G³£¤£¹ï
¤£¹LÁÙ¬OÁÂÁ±z­ò

TOP

¦^´_ 4# hsueh0926
ie8, 2003¸ê®Æ¦b .Document.all.Tags("table")(9)
½Ð­×§ï¸Õ§ä¥X¸ê®Æ¦b .Document.all.Tags("table")(??)


·P®¦ªº¤ß......(¦b³Â»¶®a±Ú°Q½×°Ï.¥Î¤ß¾Ç²ß·|¦³¶i¨Bªº)
¦ý¸ê·½µL­­,«á´©¦³­­,  ¤@¤Ñ1¤¸ªºÃÙ§U,¤H¤H¦³¯à¤O.

TOP

        ÀR«ä¦Û¦b : °µ¦n¨Æ¤£¯à¤Ö§Ú¤@¤H¡A°µÃa¨Æ¤£¯à¦h§Ú¤@¤H¡C
ªð¦^¦Cªí ¤W¤@¥DÃD