1、
Private Sub Form_Load()
Webbrowser1.navigate "http://blog.csdn.net/lbuskeep"
Do
DoEvents
If Not Webbrowser1.Busy And Webbrowser1.LocationURL <> "http://blog.csdn.net/lbuskeep" Then
MsgBox "OK"
Exit Do
End If
Loop
End Sub
Private Sub Webbrowser1_documentComplete(ByVal pdisp As Object,Url As Variant)
If (pdisp Is Webbrowser1.Object) Then
MsgBox Webbrowser1.LocationURL
End If
End Sub
2、
Private Sub Webbrowser_documentComplete(ByVal pdisp As Object,URL As Variant) '获得网页标题 If Not Webbrowser.Busy Then '判断网页是否下载完毕 Dim strTitle As String strTitle = Webbrowser.document.documentElement.INNERHTML strTitle = MID(strTitle,1,InStr(1,LCase(strTitle),"</Title>") - 1) strTitle = MID(strTitle,"<Title>") + 7) Me.Caption = strTitle End If End Sub
总结以上是内存溢出为你收集整理的VB 判断 WebBrowser是否已经加载网页完毕全部内容,希望文章能够帮你解决VB 判断 WebBrowser是否已经加载网页完毕所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)