I'm writing a function to scan through an HTML document object, and find an element based on the arguments being passed in.
Public Function GetHTMLElement(htmlDocument as HTMLDocument, sElementName as String, Optional sElementType as String)
Dim oElement as HTMLhtmlElement
Dim i as Integer
If sElementType <> "" then
For Each oElement in htmlDocument.getElementsByTagName
For i = 1 To htmlDocument.Frames.length
? = GetHTMLelement(htmlDocument.Frames(i).Document, "string", "string2")
This is all I have so far. I'm interested in returning a collection of elements that match arg2 and arg3. How do I populate this function with each element that matches the criteria? Thanks for any commets/suggestions.