vb如何强制网页只在WebBrowser中显示
很多链接都需要新窗口打开,有什么办法让新窗口也只在WebBrowser中显示,而不另弹出IE呢???谢谢!!!...
很多链接都需要新窗口打开,有什么办法让新窗口也只在WebBrowser中显示,而不另弹出IE呢???
谢谢!!! 展开
谢谢!!! 展开
2个回答
展开全部
呵呵,正好遇上。给我加点分哦!
Dim WithEvents Web_V1 As SHDocVwCtl.WebBrowser_V1
Private Sub Form_Load()
Set Web_V1 = WebBrowser1.Object
WebBrowser1.Navigate2 "www.sina.com"
End Sub
Private Sub Web_V1_NewWindow(ByVal URL As String, _
ByVal Flags As Long, _
ByVal TargetFrameName As String, _
PostData As Variant, _
ByVal Headers As String, _
Processed As Boolean)
Processed = True
WebBrowser1.Navigate URL
End Sub
Dim WithEvents Web_V1 As SHDocVwCtl.WebBrowser_V1
Private Sub Form_Load()
Set Web_V1 = WebBrowser1.Object
WebBrowser1.Navigate2 "www.sina.com"
End Sub
Private Sub Web_V1_NewWindow(ByVal URL As String, _
ByVal Flags As Long, _
ByVal TargetFrameName As String, _
PostData As Variant, _
ByVal Headers As String, _
Processed As Boolean)
Processed = True
WebBrowser1.Navigate URL
End Sub
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询