Hi,
found this code to get the html coding box for username, password when i run get the error: compile error Next without for, please help.
code:
thanks,
found this code to get the html coding box for username, password when i run get the error: compile error Next without for, please help.
code:
Code:
Private Sub GetWebsiteInfo()
On Error Resume Next
Dim ie As Object
Set ie = CreateObject("InternetExplorer.Application")
ie.navigate "https://360.allstream.com"
ie.Visible = True
Do While ie.Busy And Not ie.readyState = 4
DoEvents
Loop
DoEvents
Dim k As Integer
Do While ((ie.Busy) And (Not (ie.readyState = 4)))
DoEvents
Loop
MsgBox ("start now")
Dim i As Integer
Dim holder As Long
'j = 0
For i = 1 To ie.document.all.Length - 1
holder = 0
Sheets("Sheet1").Cells(i, 2) = ie.document.all.Item(i).tagName
Sheets("Sheet1").Cells(i, 1) = ie.document.all.Item(i).href
holder = InStr(1, ie.document.all.Item(i).href, "SuminBoxes.xls", vbTextCompare)
If holder > 0 Then
j = j + 1
Sheets("Sheet1").Cells(j, 3) = ie.document.all.Item(i).tagName
Sheets("Sheet1").Cells(j, 4) = ie.document.all.Item(i).Name
Next i
DoEvents
End Sub
thanks,