question

Bondy_Bo avatar image
588 10 14 17

OK, so how do I get the Eikon for Excel/Eikon - Microsoft Office default AdxRtHistory fields then?

eikoneikon-com-apitime-seriesexceladfin
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

DevTrev avatar image
791 10 8 14

The AdxRtHistory Class of the AdxRtLib library is the older method of retrieving time series data (interday or greater only) retained as it is a Class of the AdfinX Real Time rtx.dll Library. There are two considerations to using AdxRtHistory, 1) it can only be used for Interday or greater time periods, NOT Intraday and 2) the field names are of the old form (DATE, CLOSE etc), dating from 3000 Xtra and Powerplus 32.

To retrieve the default (all) fields use .RequestHistory("*") and then, when the data has been returned, use the ExistingFields property, an array holding the field names. Note that, unlike RHistoryAPI there is no need to infer the underlying category.fieldname, the names are the same as those that would be used in the actual request.

In the Visual Basic Editor, Tools, References for the AdfinX Real Time (or look for rtx.dll in the X/Bin, Y/Bin or Z/Bin of the TR Eikon installation directory)

Dim WithEvents myAdxRtHist As AdfinXRtLib.AdxRtHistory 
Private Sub cmdGetInterday_Click() 
Set myAdxRtHist = CreateReutersObject("AdfinXRtLib.AdxRtHistory") 

With myAdxRtHist 
	.FlushData 
	.ErrorMode = Dialogbox 
	.Source = "IDN" 
	.ItemName = "VOD.L" 
	.Mode = [H8].Value 
	.RequestHistory ("*") ' "*" requests all fields. 
End With 
Exit Sub 

Private Sub myAdxRtHist_OnUpdate(ByVal DataStatus As AdfinXRtLib.RT_DataStatus) 
Dim c As Integer 
Dim availablefields As Variant 
' If working with ALL fields request, can use .ExistingFields 
availablefields = myAdxRtHist.ExistingFields 

For c = 0 To UBound(availablefields, 1) 
Debug.Print availablefields(c, 0) 
Next c
End Sub
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.