Hello,
I'm trying to scrape what is known as the ' Yield calculation price' of a listed fixed income instrument. In order to get the right series, I have to set both a from and to date. These can be set by submitting the values to datepickers on the site, but the table underneath with the mentioned price doesn't get updated before either a javascript is called or that the 'toDate' is recognized.
I don't have much experience with how to trigger a javascript and I haven't succeed with pasting the values either. Below, you can see my short code though I would perfer to extract these values by using a XmlHttp request through http://www.nasdaqomxnordic.com/webproxy/DataFeedProxy.aspx but that I cannot figure out either.
Anyone who can take me to the next level?
Thanks in advance.
I'm trying to scrape what is known as the ' Yield calculation price' of a listed fixed income instrument. In order to get the right series, I have to set both a from and to date. These can be set by submitting the values to datepickers on the site, but the table underneath with the mentioned price doesn't get updated before either a javascript is called or that the 'toDate' is recognized.
I don't have much experience with how to trigger a javascript and I haven't succeed with pasting the values either. Below, you can see my short code though I would perfer to extract these values by using a XmlHttp request through http://www.nasdaqomxnordic.com/webproxy/DataFeedProxy.aspx but that I cannot figure out either.
Anyone who can take me to the next level?
VBA Code:
Sub GetDAta()
Dim IEapp As InternetExplorer, UrlPath As String
UrlPath = "http://www.nasdaqomxnordic.com/bonds/denmark/microsite?Instrument=XCSE5UNIK_A_26"
Set IEapp = New InternetExplorer
With IEapp
.Navigate UrlPath
.Visible = True
Do Until .readyState = READYSTATE_COMPLETE
DoEvents
Loop
With .document
.getElementById("fromDate").Value = "2019-01-01"
With .getElementById("toDate")
.Value = "2019-12-31"
.Focus
.Click
End With
End With
End With
End Sub
Thanks in advance.