- ©«¤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
|
[µo°Ý] ¦p¦ó¥H°j°é¨ú¥X«ü©wweb¤ºªº¸ê®Æ©O¡H
¦U¦ì¤j¤j¦n¡G
¤p§Ì·QÉ¥ÎEXCEL¹ïWEB¨ú¥X¸ê®Æ¡A
¤@ª½¦³¤O¤£±q¤ßªº·Pı¡C
¤p§ÌµLªk¬ð¯}n¦p¦ó«ü©w¤é´Á¤Î¤ë¥÷³v¤@¨ú¥X
¬ÛÃö¸ê®Æ¡C¸Óºô¶¨Ã³]¦³
¤@¡B½Ð¿ï¾Ü±ý¬d¸ßªº´Á§O©Î¶}¼ú¤é´Á
²Ä ´Áªº¤¤¼ú¸¹½X(¿é¤J¤E½X´Á§O¡A ¨Ò¡G096000001´Á)
¤G¡B¤¤µØ¥Á°ê 96 97 98 99 100 101 102 ¦~ 1 2 3 4 5 6 7 8 9 10 11 12 ¤ëªº¤¤¼ú¸¹½X
¤GºØ¤è¦¡³v¤@¦C¥X¡C¦Ó¤p§Ì¬On¤Þ¥Î²Ä¤GºØ¤è¦¡¨Ã¥H°j°é¤è¦¡¨Ó¹F¦¨¡C
½Ð°Ý¤p§Ìn¦p¦ó¶·¥¿¤U¦C»yªk¤~¯à¹F¦¨©O¡H
¤S¬°¦ó¨ä¨ú¥X¤§¤¤¤å·|¥X²{¶Ã½X¡A¨äì¦]¬°¦ó©O¡H
Sub test001()
Dim mSht As Worksheet
Dim mRng As Range
Dim mRow As Long, i%
Dim myURL As String
Dim myWebTbl As String
Set mSht = Worksheets(1)
'MsgBox mSht.Name
With mSht
myURL = "URL;http://www.taiwanlottery.com.tw/Lotto/Lotto649/history.aspx" '¥ô·NªºURL"
'«ü©wŪ¤Jªí³æ
For i = 1 To 100 Step 10
myWebTbl = i
'Worksheets.Add '·s¼W¤u§@ªí
With ActiveSheet.QueryTables.Add(Connection:=myURL _
, Destination:=.[a65536].End(xlUp).Offset(1)) 'Ū¤J¥Ø¼ÐÀx¦s®æ
.WebFormatting = xlWebFormattingNone '¤å¦r©ÎHTML
.WebTables = myWebTbl
.Refresh
End With
Next
End With
End Sub
ÁÂÁ¦U¦ì¤j¤j¡C |
|