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

[µo°Ý] ¥ÎVBA¸ü¤Jºô­¶¸ê®Æ

[µo°Ý] ¥ÎVBA¸ü¤Jºô­¶¸ê®Æ

¦U¦ì¦n
¦p¦ó¥ÎVBA¸ü¤Jºô­¶¸ê®Æ
http://www.taifex.com.tw/chinese/3/7_12_3_tbl.asp
ÁÂÁÂ!!

  1. Sub ¥¨¶°1()
  2.     With ActiveSheet.QueryTables.Add(Connection:= _
  3.         "URL;http://www.taifex.com.tw/chinese/3/7_12_3_tbl.asp", Destination:=Range( _
  4.         "$A$1"))
  5.         .WebFormatting = xlWebFormattingNone
  6.         .WebTables = "2"
  7.         .Refresh BackgroundQuery:=False
  8.         .Delete
  9.     End With
  10. End Sub
½Æ»s¥N½X
¦^´_ 1# pupai

TOP

¦^´_ 2# joey0415


    ½Ð°Ý§Ú¦pªG­n«ü©w¤é´Á¡A¸Ó¦p¦ó½s¼g
ÁÂÁÂ

TOP

¦^´_ 3# pupai

¤W­±ªº¥u¯à¬d³æ¤é

¤U­±ªº¤~¥i¥H¿ï¤é´Á
http://www.taifex.com.tw/chinese/3/7_12_3.asp

©Î¬O¤U­±ª½±µ¤U¸ücsv

http://www.taifex.com.tw/chinese/3/dl_7_12_8.asp

TOP

¦^´_ 4# joey0415


³o¤è¦¡§Úª¾¹D
§Ú»Ý­nªº¬O¥ÎVBA¤è¦¡«ü©w¤é´Áªº¼gªk
·PÁ¦^´_
    ÁÂÁÂ

TOP

¦^´_ 5# pupai

¸Õ¸Õ
  1. Sub CSV¤U¸ü()
  2. Dim path As String
  3. path = "C:\"
  4. ¤é´Á = "20141215"

  5. Set XML = CreateObject("Microsoft.XMLHTTP")
  6. Set stream = CreateObject("ADODB.stream")
  7.    
  8.     URL = "http://www.taifex.com.tw/chinese/3/7_12_8dl.asp?syear=" & VBA.Left(¤é´Á, 4) & "&smonth=" & VBA.Mid(¤é´Á, 5, 2) & "&sday=" & _
  9.             VBA.Right(¤é´Á, 2) & "&eyear=" & VBA.Left(¤é´Á, 4) & "&emonth=" & VBA.Mid(¤é´Á, 5, 2) & "&eday=" & VBA.Right(¤é´Á, 2)
  10.         XML.Open "GET", URL, 0
  11.         XML.send
  12.     With stream
  13.         .Type = 1
  14.         .Open
  15.         .write XML.responseBody
  16.         If Dir(path & "ÃþªÑ´Á³f" & ¤é´Á & ".csv") <> "" Then Kill (path & "ÃþªÑ´Á³f" & ¤é´Á & ".csv")
  17.         .SaveToFile (path & "ÃþªÑ´Á³f" & ¤é´Á & ".csv")
  18.         .Close
  19.     End With

  20. End Sub
½Æ»s¥N½X

TOP

¦^´_ 6# HSIEN6001


    ¬Ý¤£¬O«ÜÀ´¡A µ{¦¡°õ¦æ¦³»~ ¥X²{°õ¦æ¶¥¬q¤]»~'3004

TOP

        ÀR«ä¦Û¦b : ª¾ÃÑ­n¥Î¤ßÅé·|¡A¤~¯àÅܦ¨¦Û¤vªº´¼¼z¡C
ªð¦^¦Cªí ¤W¤@¥DÃD