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

[µo°Ý] ½Ð°ª¤â«ü¾É­×¥¿"§Y®É¦ô­p²b­È"

±z¸Õ¸Õ¬Ý
  1. Sub §Y®É²b­È()
  2. Application.ScreenUpdating = False
  3. Cells.Delete
  4. Dim E As Object, myItems As Object, myitem
  5.     With CreateObject("InternetExplorer.Application")
  6.         .Visible = True
  7.         .Navigate "http://www.yuantaetfs.com/#/RtNav/Index"
  8.         
  9.         Application.Wait Now + #12:00:03 AM#   '¦³¿ù¦b¶}±Ò

  10.         Set myItems = .Document.getElementsByTagName("button")
  11.         For Each myitem In myItems
  12.         
  13.         'Application.Wait Now + #12:00:00 AM#   '¦³¿ù¦b¶}±Ò
  14.         
  15.             If myitem.Name = "Agree" Then
  16.             
  17.                 myitem.Click    '«ö¤U°e¥X¬d¸ß«ö¶s

  18.             End If
  19.         Next

  20.         Set E = .Document.getElementsByTagName("TABLE")(22)
  21.          .Document.body.innerHTML = E.outerHTML
  22.         .ExecWB 17, 2       '  Select All
  23.         .ExecWB 12, 2       '  Copy selection
  24.         With ActiveSheet
  25.             '.Cells.Clear
  26.             .[A1].Select
  27.             .PasteSpecial Format:="HTML", Link:=False, DisplayAsIcon:=False, NoHTMLFormatting:=True
  28.         End With
  29.         .Quit        'Ãö³¬ºô­¶
  30.     End With
  31.    
  32.     x = Cells(Rows.Count, 1).End(xlUp).Row

  33.   For A = x To 6 Step -1
  34.     If Cells(A, 3) = "" Then
  35.         Rows(A).Delete
  36.     End If
  37.   Next
  38.   
  39.   Application.ScreenUpdating = True
  40. End Sub
½Æ»s¥N½X
¦^´_ 2# lcctno

TOP

¦^´_ 4# lcctno

¤p­×§ï¤@¤U¡AÀ³¸Ó¥i¥H
  1. Sub §Y®É²b­È()
  2. Application.ScreenUpdating = False
  3. Cells.Delete
  4. Dim E As Object, myItems As Object, myitem
  5.     With CreateObject("InternetExplorer.Application")
  6.         .Visible = True
  7.         .Navigate "http://www.yuantaetfs.com/#/RtNav/Index"
  8.         
  9.         Application.Wait Now + #12:00:03 AM#   '¦³¿ù¦b¶}±Ò

  10.         Set myItems = .Document.getElementsByTagName("button")
  11.         For Each myitem In myItems
  12.         
  13.         'Application.Wait Now + #12:00:00 AM#   '¦³¿ù¦b¶}±Ò
  14.         
  15.             If myitem.Name = "Agree" Then
  16.             
  17.                 myitem.Click    '«ö¤U°e¥X¬d¸ß«ö¶s

  18.             End If
  19.         Next

  20.         Set E = .Document.getElementsByTagName("TABLE")(21)
  21.          .Document.body.innerHTML = E.outerHTML
  22.         .ExecWB 17, 2       '  Select All
  23.         .ExecWB 12, 2       '  Copy selection
  24.         With ActiveSheet
  25.             '.Cells.Clear
  26.             .[A1].Select
  27.             .PasteSpecial Format:="HTML", Link:=False, DisplayAsIcon:=False, NoHTMLFormatting:=True
  28.         End With
  29.         .Quit        'Ãö³¬ºô­¶
  30.     End With
  31.     x = Cells(Rows.Count, 2).End(xlUp).Row

  32.   For A = x To 6 Step -1
  33.     If Cells(A, 4) = "" Then
  34.         Rows(A).Delete
  35.     End If
  36.   Next
  37.   Columns(1).Delete
  38.   Application.ScreenUpdating = True
  39. End Sub
½Æ»s¥N½X

TOP

¦^´_ 6# lcctno
§A¦A¸Õ¸Õ
  1. Sub §Y®É²b­È()
  2. Application.ScreenUpdating = False
  3. Cells.Delete
  4. Dim E As Object, myItems As Object, myitem
  5.     With CreateObject("InternetExplorer.Application")
  6.         .Visible = True
  7.         .Navigate "http://www.yuantaetfs.com/#/RtNav/Index"
  8.         
  9.         Application.Wait Now + #12:00:03 AM#   '¦³¿ù¦b¶}±Ò

  10.         Set myItems = .Document.getElementsByTagName("button")
  11.         For Each myitem In myItems
  12.         
  13.         'Application.Wait Now + #12:00:00 AM#   '¦³¿ù¦b¶}±Ò
  14.         
  15.             If myitem.Name = "Agree" Then
  16.                 myitem.Click    '«ö¤U°e¥X¬d¸ß«ö¶s
  17.             End If
  18.         Next
  19.             Set r = .Document.All.tags("table")(22).Rows
  20.             n = Cells(Rows.Count, 1).End(xlUp).Row
  21.             For i = 2 To r.Length - 1
  22.                 For j = 0 To r(i).Cells.Length - 2
  23.                     Cells(i + n + 1 - 3, j + 1) = r(i).Cells(j).innerText
  24.                 Next j
  25.             Next
  26.             
  27.         x = Cells(Rows.Count, 1).End(xlUp).Row
  28.             For A = x To 1 Step -1
  29.               If Cells(A, 3) = "" Then
  30.                   Rows(A).Delete
  31.               End If
  32.             Next
  33.         .Quit
  34.         End With
  35.   
  36.   Application.ScreenUpdating = True
  37. End Sub
½Æ»s¥N½X

TOP

        ÀR«ä¦Û¦b : ¬Ý§O¤H¤£¶¶²´¡A¬O¦Û¤v­×¾i¤£°÷¡C
ªð¦^¦Cªí ¤W¤@¥DÃD