Our training courses

Other training resources

Our training venues

Why we are different

Details for Raveendra

Raveendra has participated in the following threads:

Added by Raveendra on 31 Mar 2021 at 12:55

I wanted to get each pic url but the code is not executing. After a lot of research i coudn't find the reason.  Can you please let me know where i am going wrong?

Const WolVidURL As String = "https://www.coldwellbankerhomes.com/mi/baroda/agents/"

Sub GetVideoPage()

    Dim XMLReq As New MSXML2.XMLHTTP60
    Dim HTMLDoc As New MSHTML.HTMLDocument
    
    Dim VidCats As MSHTML.IHTMLElementCollection
    Dim VidCat As MSHTML.IHTMLElement
    Dim VidCatList As MSHTML.IHTMLElement
    
    Dim i As Integer
    
    XMLReq.Open "GET", WolVidURL, False
    XMLReq.send
    
    If XMLReq.Status <> 200 Then
        MsgBox "Problem" & vbNewLine & XMLReq.Status & " - " & XMLReq.StatusText
        Exit Sub
    End If
    
    HTMLDoc.body.innerHTML = XMLReq.responseText
    Set VidCatList = HTMLDoc.getElementsByClassName("split-4 agent-team-results")(0)
    Set VidCats = VidCatList.getElementsByTagName("a")
         i = 2
    For Each VidCat In VidCats
        If VidCat.className = "image-wrap" Then
            Cells(i, 2) = VidCat.getAttribute("href")
            i = i + 1
        End If
    Next VidCat
   
    
End Sub

Head office

Kingsmoor House

Railway Street

GLOSSOP

SK13 2AA

London

Landmark Offices

99 Bishopsgate

LONDON

EC2M 3XD

Manchester

Holiday Inn

25 Aytoun Street

MANCHESTER

M1 3AE

© Wise Owl Business Solutions Ltd 2024. All Rights Reserved.

End of small page here
Please be aware that our website uses cookies!
I'm OK with this Tell me more ...