Hello,
I'm trying to get data from a web page that, apparently, is constructed such a way that I don't get all data that appears.
Coinmarketcap historical data
Here's the code I'm using :
I do not get the historical data. I tried to save the page to an HTML format locally, and, in the file, the data is present, so there must be a way, but I can't seem to find it.
Any idea ?
Thanks !
I'm trying to get data from a web page that, apparently, is constructed such a way that I don't get all data that appears.
Coinmarketcap historical data
Here's the code I'm using :
VBA Code:
Const WebQueriesSheet = "Web_Queries"
Sub TestWeb()
Send_Query ("URL;https://coinmarketcap.com/currencies/" & "Bitcoin") ' Calls for the web query
End Sub
Sub Send_Query(URL)
Sheets(WebQueriesSheet).Range("A:Z").Delete
Sheets(WebQueriesSheet).Cells.ClearContents
With Sheets(WebQueriesSheet).QueryTables.Add(Connection:=URL, Destination:=Sheets(WebQueriesSheet).Range("A1"))
.WebSelectionType = xlEntirePage
.WebFormatting = xlWebFormattingNone
.WebDisableDateRecognition = True
.WebPreFormattedTextToColumns = True
.WebConsecutiveDelimitersAsOne = True
.WebDisableRedirections = False
.Refresh BackgroundQuery:=False
End With
For Each cn In ThisWorkbook.Connections
cn.Delete
Next cn
End Sub
I do not get the historical data. I tried to save the page to an HTML format locally, and, in the file, the data is present, so there must be a way, but I can't seem to find it.
Any idea ?
Thanks !