'问题:如何用htmldocument不弹出广告及脚本错误!如:该页包含未知的潜在安全缺陷,是否继续?
'ie或webbrowser可以用上网助手,slient属性或禁用脚本,可htmldocument不能直接用ie设定,有何妙计?
'在菜单工程》》引用》》中选中:Microsoft Html Object Libary
Private Sub Form_Load()
Command1_Click
End Sub
Private Sub Command1_Click()
'测试htmldocument错误的脚本
Dim doc1 As HTMLDocument
Dim doc2 As HTMLDocument
Set doc2 = New HTMLDocument
   Set doc1 = doc2.createDocumentFromUrl("http://www.163.com", vbNullString)
    Do Until doc1.readyState = "complete"
        DoEvents
    Loop
   MsgBox doc1.body.innerHTML
End Sub