I got 1000s of rows of URLs and for each row I am using:
For i = 2 to last row
Set links = html.getElementsByTagName("a")
For Each lnk In links
If lnk.innertext = "something" then
do something
end if
Next lnk
Next i
a method coomonly used, I guess, and as a ref shown by Sid's code at How to access innerText of HTML tag inside a <TD> tag
Is For loop (the one for each lnk)
, pretty much the only method in this scenario or are there faster efficient methods?
MATCH is probably used only for sheet ranges, but tried it anyways. It runs w/o error, does nothing and takes the same time as the For loop
method. I think it does nothing due to the lack of appropriate addressing in :
If Not IsError(Application.Match("something", Range("A1:A100"), 0)) 'normally used for ranges
If Not IsError(Application.Match("something", links.innertext, 0)) 'what I tried