1.vb ?浏览b浏览器???? Դ??
2.VBä¸çWebBrowser1
3.怎样让所有的网页都用VB做的浏览器打开?
vb ????? Դ??
代码如下:
Private Sub Command1_Click()
WebBrowser1.Navigate Text1.Text
End Sub
Private Sub Command2_Click()
WebBrowser1.GoBack
End Sub
Private Sub Command3_Click()
WebBrowser1.GoForward
End Sub
Private Sub WebBrowser1_BeforeNavigate(ByVal URL As String, ByVal Flags As Long, ByVal TargetFrameName As String, PostData As Variant, ByVal Headers As String, Cancel As Boolean)
Text1.Text = URL
End Sub
这样就行了
VBä¸çWebBrowser1
è¯è¯è¿ä¸ªåæ³ï¼
建ç«ä¸ä¸ªwb(0),Visible=False
(WBæ¯WebBrowseræ§ä»¶æ°ç»ââåªè¦è®¾ç½®å®çIndex=0è¿æVisible=Falseå³å¯ï¼
代ç æ¯ï¼
Sub InitWB(Optional Update As Boolean=False)
If Update Then Unload(wb(1))
Load wb(1)
wb(1).visible = true
wb(1).left = 0
wb(1).top = 0
wb(1).width =
wb(1).height = 'åå§åå®ç尺寸åæ ä½ èªå·±å
'å¦æè¿æå ¶ä»å±æ§è®¾ç½®è¿éå ä¸
End Sub
Private Sub Form_Load()
InitWB
End Sub
å¦æè¦æ´æ°ï¼è°ç¨è¯å¥Call InitWB(true)
è¿æ ·åºè¯¥æ¯å¯ä»¥çã
ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼ï¼
建ç«ä¸ä¸ªWebrowser1,å½å为wbï¼è®¾ç½®ä»çå±æ§index=0
ç¶åç¨ä¸é¢ä»£ç
怎样让所有的网页都用VB做的浏览器打开?
楼主不用怕,试一下我的器源多多分享 源码这个代码,可以如你所愿了。源码花狸影视源码
新建一个WebBrowser1,浏览b浏览器个人留言网源码
代码如下:
Private Sub WebBrowser1_NewWindow2(ppDisp As Object, Cancel As Boolean)
Dim newform1 As New Form1
Set ppDisp = newform1.WebBrowser1.object
newform1.Show
End Sub
Private Sub Form_Load()
WebBrowser1.Navigate "" '''''你想要打开的网页
End Sub
2024-11-26 08:37
2024-11-26 08:19
2024-11-26 07:17
2024-11-26 06:29
2024-11-26 06:06
2024-11-26 06:02