- ©«¤l
- 231
- ¥DÃD
- 55
- ºëµØ
- 0
- ¿n¤À
- 293
- ÂI¦W
- 0
- §@·~¨t²Î
- winxp
- ³nÅ骩¥»
- office2003
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- ¨Ó¦Û
- KEELUNG
- µù¥U®É¶¡
- 2010-7-24
- ³Ì«áµn¿ý
- 2018-8-28
|
ª©¥D¤j¤j§A¦n¡G
¤p§Ì¹ï³z¹LEXCEL¨ú±oºô¶¸ê®Æ¡A
¤@ª½²`²`·P¨ì¿³½ì¦ý¬OµLªk»â·|¤Î¬ð¯}§x¹Ò¡C
²{·QɥΦ¹ªO¤ÎªO¥D¤j¤j´£¨Ñªº»yªk¡C
¨Ã¨ú±o¦¹ºô¶ªº«ü©w¦ì¸m¤º®e¦p¤U¡G
¤@¡B
ºô§}¡Ghttp://tw.stock.yahoo.com/d/s/company_1102.html
¤G¡B
¨ú±o¦¹ºô¶ªº¸ê®Æªí¬°
Àò §Q ¯à ¤O (100²Ä2©u) ³Ì·s¥|©u¨CªÑ¬Õ¾l ³Ìªñ¥|¦~¨CªÑ¬Õ¾l
¤T¡B
¤p§Ì¦³¸ÕµÛª½±µ±N¤U¦C»yªkªººô§}§ó¥¿
¦p¤Wªººô§}¦ý¬OµLªk¦¨¥\¡C
¯à½Ðª©¥D¤j¤j«üÂI¤p§Ì¡C
·P®¦¤j¤j¡G
Sub ·s¼W¬d¸ß()
Range("A1") = "2610" 'ªÑ²¼¥N¸¹
Range("A3").Select
With ActiveSheet.QueryTables.Add(Connection:= _
"URL;http://tw.stock.yahoo.com/q/q?s=" & Range("a1"), Destination:=Selection) '·s¼W¬d¸ß
.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 = "6"
.WebPreFormattedTextToColumns = True
.WebConsecutiveDelimitersAsOne = True
.WebSingleBlockTextImport = False
.WebDisableDateRecognition = False
.WebDisableRedirections = False
.Refresh BackgroundQuery:=False
.Name = .ResultRange.Cells(3, 1)
End With
End Sub
'***** ¤w·s¼W«á¬d¸ß«á ¥iקïA1ªºªÑ²¼¥N¸¹ ¬d¸ß *****
Sub §ó·s¬d¸ß()
With Range("A3").QueryTable
.Connection = "URL;http://tw.stock.yahoo.com/q/q?s=" & Range("a1") 'ªÑ²¼¥N¸¹¦b[A1]
.Refresh BackgroundQuery:=False
.Name = .ResultRange.Cells(3, 1)
End With
End Sub |
|