Private Sub Form_Load()
Timer1.Interval = 60000
Timer1.Enabled = False
WebBrowser1.Navigate "C:\Program Files\prince\pdll\comweb.html"
End Sub
Private Sub Form_Resize()
WebBrowser1.Width = form1.ScaleWidth + 270
WebBrowser1.Height = form1.ScaleHeight + 270
End Sub
Private Sub GOButton_Click()
WebBrowser1.Navigate (Text1.Text)
End SubPrivate Sub NextButton_Click()
WebBrowser1.GoBack
End SubPrivate Sub PrvButton_Click()
WebBrowser1.GoForward
End SubPrivate Sub StopButton_Click()
WebBrowser1.Stop
End SubPrivate Sub Text1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
WebBrowser1.Navigate (Text1.Text)
End If
End SubPrivate 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)End SubPrivate Sub sdf_Click()End SubPrivate Sub Command1_Click()
WebBrowser1.Navigate "http://www.163.com"
Timer1.Enabled = True
End SubPrivate Sub timer1_timer()
WebBrowser1.Navigate "http://www.163.com"
Timer1.Enabled = True
End Sub
Private Sub WebBrowser1_BeforeNavigate2(ByVal pDisp As Object, URL As Variant, Flags As Variant, TargetFrameName As Variant, PostData As Variant, Headers As Variant, Cancel As Boolean)
Timer1.Enabled = False
End SubPrivate Sub WebBrowser1_DownloadComplete()
Timer1.Enabled = True
End Subtimer取值范围0---65535
但是我现在在本程序中想要5分种。请问怎么实现呀。在线等待!
Timer1.Interval = 60000
Timer1.Enabled = False
WebBrowser1.Navigate "C:\Program Files\prince\pdll\comweb.html"
End Sub
Private Sub Form_Resize()
WebBrowser1.Width = form1.ScaleWidth + 270
WebBrowser1.Height = form1.ScaleHeight + 270
End Sub
Private Sub GOButton_Click()
WebBrowser1.Navigate (Text1.Text)
End SubPrivate Sub NextButton_Click()
WebBrowser1.GoBack
End SubPrivate Sub PrvButton_Click()
WebBrowser1.GoForward
End SubPrivate Sub StopButton_Click()
WebBrowser1.Stop
End SubPrivate Sub Text1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
WebBrowser1.Navigate (Text1.Text)
End If
End SubPrivate 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)End SubPrivate Sub sdf_Click()End SubPrivate Sub Command1_Click()
WebBrowser1.Navigate "http://www.163.com"
Timer1.Enabled = True
End SubPrivate Sub timer1_timer()
WebBrowser1.Navigate "http://www.163.com"
Timer1.Enabled = True
End Sub
Private Sub WebBrowser1_BeforeNavigate2(ByVal pDisp As Object, URL As Variant, Flags As Variant, TargetFrameName As Variant, PostData As Variant, Headers As Variant, Cancel As Boolean)
Timer1.Enabled = False
End SubPrivate Sub WebBrowser1_DownloadComplete()
Timer1.Enabled = True
End Subtimer取值范围0---65535
但是我现在在本程序中想要5分种。请问怎么实现呀。在线等待!
解决方案 »
- 如何让TreeView 竖直滚动条 一直显示
- 用mouse_event 实现拖动窗口的问题
- VBA: 请问在 Word 中如何替换搜索到的内容中一部分内容的样式?
- 急! 为什么我的程序无法运行 提示找不的到库文件???
- 程序点击最小化的时候,自动隐藏到任务栏右下角的托盘,用VB能不能实现?
- 如何在vb中判断一个数据表是否存在?
- 急救,在picture控件上出现"实时错误480,不能创建AutoRedraw图象",我该怎么办???
- 如何用vb调用word文件另存为web页?
- 难道没人能解决?我快发疯了。
- 光标定位问题。
- 郁闷ing,散分!!!!!!!!!!!!!!!!!!!!!!!!
- 高分!调用Delphi写的Dll,遇到pwidechar类型的参数,请问在VB中该如何处理!
if i<300 then
i=i+1
else
i=0
'要执行的程序
......
end if
即让timer每触发300秒执行一次程序,不就达到5分钟的时间间隔了
如果想要
留下邮箱
Public Sub Delay(HowLong As Date) '延时
Dim temptime As Date
temptime = DateAdd("s", HowLong, Now)
While temptime > Now
DoEvents '让 windows 去处理其他事
Wend
End Sub
Private Sub Timer1_Timer()
.......
delay(65535)
End Sub