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

[µo°Ý] µLªk¶×¤JPCHOME ªÑ¥«¸ê®Æ

GBKEE ¤j¤j
¤ï¶Õ¡A§Úªº°ÝÃD¥´¿ù¤F¡C
§Ú¬O­n°Ý§Ú¨Ï¥Î§Aªºµ{¦¡½X¦p¦óÅýhttp://pchome.syspower.com.tw/stock/sto2/ock2/sid2330.html
¥i¥H¿ï¾Ü¤£¦PªºªÑ²¼¥N½X¶×¤J³oºô­¶ªº¸ê®Æ
¥i§_«ü¾É¤@¤U¡C

TOP

­Y±N¥N¸¹©ñ¦ba1ªº¦ì¸m¡AÀ³¸Ó¬O³o¼Ë¼g§a¡I
WebAddress = "/pchome.syspower.com.tw/stock/sto2/ock2/sid" & [A1] & ".htm"

TOP

¦^´_ 20# hsiao13

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

TOP

¦^´_ 2# GBKEE
§Ú·Q°Ý¦p¦ó¯à¦bexcel¤¤¥i¥Hª½±µ¿é¤J¥N½X¡A¦b¤j¤jªºµ{¦¡½X¤¤¥u¦³2330¯à¿é¥X¡I

TOP

¦^´_  GBKEE
§Ú·Q°Ý¦p¦ó¯à¦bexcel¤¤¥i¥Hª½±µ¿é¤J¥N½X¡A¦b¤j¤jªºµ{¦¡½X¤¤¥u¦³2330¯à¿é¥X¡I
hsiao13 µoªí©ó 2013/12/26 17:25


­n¦bexcel¤¤ª½±µ¿é¤J¥N½X, cji3cj6xu6 22# ¥i°Ñ¦Ò,¦ý³oºô­¶µLªk¶×¤J¸ê®Æ.
·P®¦ªº¤ß......(¦b³Â»¶®a±Ú°Q½×°Ï.¥Î¤ß¾Ç²ß·|¦³¶i¨Bªº)
¦ý¸ê·½µL­­,«á´©¦³­­,  ¤@¤Ñ1¤¸ªºÃÙ§U,¤H¤H¦³¯à¤O.

TOP

¦^´_ 25# GBKEE
¦^´_ 24# hsiao13
24# À³¸Ó¬O«ü2#ªº¤èªk§a¡H
¤ñ·Ó7# InputBox ­×§ï´N¦n¤F¡C¡C¡C

TOP

½Ð°Ý¦U¦ì¤j¤j,¬°¤°»ò§Ú³o¼Ë¼g¨S¦³¿ìªk§ì¨ú pchome ªÑ²¼±Æ¦æ
¦p¥H¤Uºô§}: http://pchome.megatime.com.tw/rank/sto0/ock08.html
³£·|§ì¨ìªÅ¥Õ,
Sub §ì¨C¤ëÀ禬(weburl As String)
    Sheets("Temp").Activate           
                                      
    With ActiveSheet.QueryTables.Add(Connection:= _
        "URL;" & weburl, Destination:=Range("A1"))
         .FieldNames = True
        .RowNumbers = False
        .FillAdjacentFormulas = False
        .PreserveFormatting = True
        .RefreshOnFileOpen = False
        .BackgroundQuery = True
        .RefreshStyle = xlInsertDeleteCells
        .SavePassword = False
        .SaveData = True
        .AdjustColumnWidth = True
        .RefreshPeriod = 0
        .WebSelectionType = xlSpecifiedTables
        .WebFormatting = xlWebFormattingNone
        .WebTables = "7"
        .WebPreFormattedTextToColumns = True
        .WebConsecutiveDelimitersAsOne = True
        .WebSingleBlockTextImport = False
        .WebDisableDateRecognition = False
        .WebDisableRedirections = False
        .Refresh BackgroundQuery:=False

    End With
End Sub

TOP

¦^´_ 27# iorikoyzz

³oºô­¶ ¥ÎQueryTablesµL®Ä
¸Õ¸Õ¬Ý
  1. Option Explicit
  2. Sub §ì¨C¤ëÀ禬(weburl As String)
  3.     Dim i As Integer, E As Object, K, R
  4.     Sheets("Temp").Activate
  5.     ActiveSheet.Cells.Clear
  6.     With CreateObject("InternetExplorer.Application")
  7.         .Visible = True 'Åã¥Üºô­¶
  8.         .Navigate weburl
  9.         Do While .Busy Or .readyState <> 4: DoEvents: Loop
  10.         Set E = .Document.all.TAGS("TABLE")(0)
  11.         K = 1
  12.         For Each R In E.Rows
  13.             For i = 0 To R.Cells.Length - 1
  14.                 ActiveSheet.Cells(K, i + 1) = R.Cells(i).INNERTEXT
  15.             Next
  16.             K = K + 1
  17.         Next
  18.         .Quit        'Ãö³¬ºô­¶
  19.     End With
  20. End Sub
½Æ»s¥N½X
·P®¦ªº¤ß......(¦b³Â»¶®a±Ú°Q½×°Ï.¥Î¤ß¾Ç²ß·|¦³¶i¨Bªº)
¦ý¸ê·½µL­­,«á´©¦³­­,  ¤@¤Ñ1¤¸ªºÃÙ§U,¤H¤H¦³¯à¤O.

TOP

Hi GBKEE¤j¤j:

§A¤Ó±j¤F,³o¥i¥H¥Î
«D±`ÁÂÁ§A!!,
¤£¹L³o¬O¬°¤°»ò©O??

thanks

TOP

        ÀR«ä¦Û¦b : ¡i®É¤é²öªÅ¹L¡j¤@­Ó¤H¦b¥@¶¡°µ¤F¦h¤Ö¨Æ¡A´Nµ¥©ó¹Ø©R¦³¦hªø¡C¦]¦¹¥²¶·»P®É¶¡Ävª§¡A¤Á²ö¨Ï®É¤éªÅ¹L¡C
ªð¦^¦Cªí ¤W¤@¥DÃD