我有一些VBA代码实际上启动了一个网页并读取了数据内容。
Sub Retrieve_Info()
If First_Time = True Then
IE_Sledgehammer
Set IE = CreateObject("InternetExplorer.Application")
IE.Visible = True
End If
PACN = Cells(Row, 1)
IE.Navigate "http://www.myWebReportPage.com/Apps/AddIssues/EditIssue.asp?IssueID=" & PACN & "&ProjectID=PACN"
If First_Time = True Then
Sleep 10000
First_Time = False
Else
Sleep 3000
End If
On Error Resume Next
Source_Code = IE.document.DocumentElement.innerText
Do Until InStr(1, Source_Code, "Issue Id") <> 0 Or InStr(1, Source_Code, "Unable to locate") <> 0
Source_Code = IE.document.DocumentElement.innerText
Sleep 100
Loop
Sleep 200
Source_Code = IE.document.DocumentElement.innerText
Source_Code2 = IE.document.DocumentElement.innerHTML
End Sub
问题是这个代码在IE 8中运行良好但在IE9中挂起。
非常感谢任何帮助。