NDaphid
07-17-2003, 09:21 PM
OK...after several alterations with help, I've arrived at the following code...still will not work...what's wrong now?
Example:
Private Sub Form_Load()
End Sub
Dim urls As String
Dim current As Integer
urls(0) = "www.google.com"
urls(1) = "www.aol.com"
urls(2) = "www.hp.com"
urls(3) = "www.yahoo.com"
Sub Command1_Click() 'Next button
If current < 4 Then current = current + 1
WebBrowser1.navigate urls(current)
End Sub
Sub Command2_Click() 'Back button
If current > 0 Then current = current - 1
WebBrowser1.navigate urls(current)
End Sub
What I'm getting is: Compile error. Sub or function not defined...then in the code: urls is highlighted.
Any help would be appreciated...thanks!
Example:
Private Sub Form_Load()
End Sub
Dim urls As String
Dim current As Integer
urls(0) = "www.google.com"
urls(1) = "www.aol.com"
urls(2) = "www.hp.com"
urls(3) = "www.yahoo.com"
Sub Command1_Click() 'Next button
If current < 4 Then current = current + 1
WebBrowser1.navigate urls(current)
End Sub
Sub Command2_Click() 'Back button
If current > 0 Then current = current - 1
WebBrowser1.navigate urls(current)
End Sub
What I'm getting is: Compile error. Sub or function not defined...then in the code: urls is highlighted.
Any help would be appreciated...thanks!