... Dim html As HTMLDocument Dim ElementCol As Object Dim link As Object Set html = mIE.document Set ElementCol = html.getElementsByTagName("a") For Each link In ElementCol If Left(link, 10) = "acestream:" Then r = r + 1 Cells(r, 1) = link End If Next ...