|
楼主 |
发表于 2010-12-29 09:39
|
显示全部楼层
[广告] VBA代码宝 - VBA编程加强工具 · VBA代码随查随用 · 内置多项VBA编程加强工具 ★ 免费下载 ★ ★ 使用手册★
我谷歌了一下
Sub ThunderDown()
Dim http As Object
Dim ThunderAgent As Object
Dim i As Long, j As Long
Dim Arr() As String
Dim EndRow As Long
Dim Temp As String
EndRow = [A65536].End(xlUp).Row
ReDim Arr(1 To 1)
Set http = CreateObject("Microsoft.XMLHTTP")
With http
For i = 1 To EndRow
.Open "get", Cells(i, 1), False
.send ""
Temp = .responsetext
If InStr(1, Temp, "thunderHref") > 0 Then
j = j + 1
ReDim Preserve Arr(1 To j)
Arr(j) = Split(Split(.responsetext, "thunderHref='")(1), "'")(0)
End If
Next
End With
Set ThunderAgent = CreateObject("ThunderAgent.Agent.1")
With ThunderAgent
For i = 1 To UBound(Arr)
.addtask Arr(i)
Next
.CommitTasks
End With
End Sub
以上代码可以用吗? 如何编辑成我的链接中的“数据表”呢 、我不会弄。 请达人帮忙。。 |
|