Hello,
I have this code that works but only for one row or last row in table. How could it be modified to output all the rows in a table. I considered obtaining the number of rows shown on page and modify loop but all entries are just the last entry in table. Any help appreciated thanks
Mike
Code:Set the_input_elements = objIE.document.getElementsByTagName("td") For Each input_element In the_input_elements If input_element.getAttribute("headers") = "STREET_NO" Then Cells(i, 3) = input_element.innerText ElseIf input_element.getAttribute("headers") = "STREET_NAME" Then Cells(i, 4) = input_element.innerText ElseIf input_element.getAttribute("headers") = "POSTAL_CODE" Then Cells(i, 5) = input_element.innerText ElseIf input_element.getAttribute("headers") = "BUSINESS_NAME" Then Cells(i, 6) = input_element.innerText ElseIf input_element.getAttribute("headers") = "ACCOUNT_STATUS" Then Cells(i, 7) = input_element.innerText End If Next input_element




Reply With Quote
