Gruppe
Extern
Problem
Bei Google soll eine Suchanfrage gestartet und aus der Ergebnisliste alle Links in einer Tabelle gelistet werden.
StandardModule: Modul1
Sub HTMLAuslesen()
Dim wks As Worksheet
Dim lRow As Integer, iRow As Integer, iRowT As Integer
Dim sSearch As String
sSearch = "http://www.google.de/search?"
sSearch = sSearch & "q=excel&hl=de&btnG=Google-Suche"
sSearch = sSearch & "&meta=lr%3Dlang_de"
Application.ScreenUpdating = False
Workbooks.Open sSearch
Set wks = ActiveSheet
lRow = wks.Cells(Rows.Count, 1).End(xlUp).Row
Workbooks.Add
For iRow = 1 To lRow
If wks.Cells(iRow, 1).Hyperlinks.Count = 1 Then
iRowT = iRowT + 1
Cells(iRowT, 1) = wks.Cells(iRow, 1).Hyperlinks(1).Address
End If
Next iRow
wks.Parent.Close savechanges:=False
Application.ScreenUpdating = True
End Sub