I'm trying to import to Excel a list of exhibitors and countries from this webpage and I'm not getting it.
Can Someone help me?
I have tried the methods listed in this forum and doesn't work.
Sub test()
Dim objIE As Object
Dim hmtl As HTMLDocument
Dim elements As IHTMLElementCollection
Set objIE = New InternetExplorer
objIE.Visible = True
objIE.navigate "https://sps.mesago.com/events/en/exhibitors_products/exhibitor-list.html"
Application.StatusBar = "Loading, Please wait..."
While objIE.Busy
DoEvents
Wend
Do
Loop Until objIE.readyState = READYSTATE_COMPLETE
Application.StatusBar = "Importing data..."
Set html = objIE.document
'I try differents types and name - ByClassName("..."), ByTagName("..."), ...
Set elements = html.getElementsByClassName("list")
For i = 0 To elements.Length - 1
Sheet1.Range("A" & (i + 1)) = elements(i).innerText
Next i
objIE.Quit
Set objIE = Nothing
Application.StatusBar = ""
End Sub
Sorry about my English.