Hello all,
I'm trying to import some data for a fund listed on the Luxembourg SE. When I go to the site, I can insert the ISIN code, LU1883863935, in the search field and from there I can read the exchange symbol, 294814.
As I'm trying to get the data into Excel, I can see when I use Inspect, Network, Xhr that the symbol appears to be found utilizing this URL by a WinHttpRequest with a POST. A Request Payload seems to be added as well.
I thought that this code could be used to read the symbol (294814)
but each time, it times out? I have to admit that I'm not that familiar with POST requests, but looking at the network traffic, I think I'm close...
Anyone who can see what I'm missing in my request?
/S_White
I'm trying to import some data for a fund listed on the Luxembourg SE. When I go to the site, I can insert the ISIN code, LU1883863935, in the search field and from there I can read the exchange symbol, 294814.
As I'm trying to get the data into Excel, I can see when I use Inspect, Network, Xhr that the symbol appears to be found utilizing this URL by a WinHttpRequest with a POST. A Request Payload seems to be added as well.
I thought that this code could be used to read the symbol (294814)
VBA Code:
Sub GetSymbol()
Dim WinHttp As New WinHttpRequest, HtmlDoc As New HTMLDocument, BodyStr As String
BodyStr = "{query: ""LU1883863935"", affiner: []}"
With WinHttp
.Open "POST", "https://www.bourse.lu/api/search/", False
.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
.send BodyStr
HtmlDoc.body.innerHTML = .responseText
End With
End Sub
but each time, it times out? I have to admit that I'm not that familiar with POST requests, but looking at the network traffic, I think I'm close...
Anyone who can see what I'm missing in my request?
/S_White