how do I initialize AdxRtHistory

code.txt

Trying to create a com object for Interday data from Eikon com/.net API

I initialize myAdxRtHist as follows:

Dim WithEvents myAdxRtHist As ThomsonReuters.Interop.RTX.AdxRtHistory

However I always get myAdxRtHist equal to nothing when i try to request the data as follows:

The attached file has the function with the problem starting on line 59. What do i need to initialize myAdxRtHist to within the function? I'm using Interop.RTX.dll as a reference.

Best Answer

  • Jirapongse
    Jirapongse ✭✭✭✭✭
    Answer ✓

    You can use MyEikonDesktopDataAPI.CreateAdxRtHistory() to create an instance of AdxRtHistory.

    If myAdxRtHistory Is Nothing Then
    Try
    Dim obj As Object = MyEikonDesktopDataAPI.CreateAdxRtHistory()
    myAdxRtHist= CObj(obj)
    Catch ex As Exception
    myAdxRtHist = Nothing
    End Try
    End If

Answers

Welcome!

It looks like you're new here. Sign in or register to get started.

Welcome!

It looks like you're new here. Sign in or register to get started.