Public StrUrl() As String '先定义一个字符串数组来保存text1里的网址
Public n As Integer '定义一个整型变量,用来记录打开过的网址
Private Sub Command1_Click()
StrUrl = Split(Text1, ",") '这里假设网址之间是用逗号隔开的
n = UBound(StrUrl)
Timer1.Interval = 5000 '设置计时器 5秒
Timer1.Enabled = True
End Sub
Private Sub Timer1_Timer()
If n >= 0 Then
Webbroeser1.Navigate StrUrl(n) '打开网页
Text1 = Replace(Text1, StrUrl(n), "") '删除已打开的网址
n = n - 1
Else
Timer1.Enabled = False
End If
End Sub