DEX2 COM API & VBA : Currency field generating an automation error

Bonjour,

requesting currency with DEX2 is generating an automation error.

In my Dex2 class module if I setup a function with :

m_rdata.FieldList = "CURRENCY"

It gets no results although I can get one using the TR function in an excel spreadsheet.

The function is working with some fields such as m_rdata.FieldList = "TR.LipperRiccode" or "TR.NETASSETVAL" or "TR.PriceClose" so I guess this is related to the fields currency in itself. "CF_CURR" is generating the same error.

Any idea please ?

merci,

OR

Best Answer

  • olivier.r
    Answer ✓

    Merci.

    I need to dig into AdfinX then. A third API alonsgside DEX2 & Rhistory. It was far more simpler in Bloomberg...

Answers

  • I'm afraid the behavior you experienced is expected. DEX2 library can only be used to retrieve fields from fundamental & reference set. These fields can be identified by their names, which all start with "TR.". Fields whose names don't start with "TR." such as CURRENCY, CF_CURR etc. come from the real-time data stream and can be retrieved using AdfinX Real-Time COM library.

  • How can it be that there is no "currency" field in the fundamental data? That would mean that I cannot know in which currency a TR.PriceClose is?

  • You could go for TR.PriceClose.currency, respectively TR.FiCurrency for bonds or TR.Fundcurrency for Funds. Just be aware that the first two return ISO-Codes whereas the third is a normal Text, like USDollars instead of USD.

    Not so consistent :/