question

Upvotes
Accepted
1 1 0 5

Contribute and get a status

I am trying to use the Eikon desktop api in c#. I am able to contribute to a RIC using the below

AdxRtContribute contrib = _eikonConn.CreateAdxRtContribute();

However I need to figure out if the contribution went through or if there is an exception. Is that possible?

Also the Eikon desktop api requires the Eikon desktop to be up and running on the users machine. Is there a way to launch it in case it is not running on the users machine?

Thanks.

Ganesh

eikoneikon-data-apieikon-com-api
icon clock
10 |1500

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

Upvotes
Accepted
39.2k 75 11 27

When you use Eikon COM APIs in custom applications, Eikon will be launched automatically if it's not already running at the time application establishes connection with Eikon.
Specifically calling Initialize method of EikonDesktopDataAPI class will launch Eikon if it's not already running.
I'm afraid AdxRtContribute object does not provide any feedback on contributions. If you're contributing to an internal record you could possibly devise a field in that record to hold contribution sequence number. Then with every contribution you could send an incremented value to this field, and using AdxRtList object subscribe to the updates for the record and match the sequence number received with the sequence number contributed. This is the only way you can verify success of contribution using Eikon APIs.

icon clock
10 |1500

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

Thanks for the quick response Alex. I initialize the api like below, but the OnStatusChanged event does not get called until I manually launch Eikon desktop.

_eikonConn = new EikonDesktopDataAPI.EikonDesktopDataAPI(); _eikonConn.OnStatusChanged += EikonConn_OnStatusChanged;

var connectResult = _eikonConn.Initialize();

The connectResult is succeeded, but the OnStatusChanged isn't firing. Am I missing something here?

I see my eikon desktop running in my task bar, but the OnStatusChanged gets invoked only when I double click the eikon icon to launch the toolbar.

Upvotes
1 1 0 5

Another issue is if I try to initialize the eikon api inside a xll (using exceldna) on AutoOpen of the add-in, then the sheet just crashes! Is that not meant to be used inside a xll?

icon clock
10 |1500

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

Upvotes
39.2k 75 11 27

EikonDesktopDataAPI library is intended for use in custom applications, not in MS Office. Eikon COM APIs have never been tested for use in an xll. We don't quite know what behavior you should expect. Eikon installs a COM add-in for Excel. If you have loaded this COM add-in, which adds Thomson Reuters tab to Eikon ribbon, into your Excel session, then you definitely cannot use EikonDesktopDataAPI library in the same Excel process. Instead you can try instantiating AdxRtContribute and other Eikon COM APIs objects by calling CreateReutersObject function of PLVbaApis.dll. This is how Eikon COM APIs objects are instantiated in Excel VBA. See the section on this portal dedicated to using Eikon COM APIs in MS Office including Quick Start Guide and tutorials.

https://developers.refinitiv.com/en/api-catalog/eikon/com-apis-for-use-in-microsoft-office
For list of progIDs you can pass to CreateReutersObject function examine PLVbaApis.bas VBA module installed with Eikon.
I suppose your previous comments were also related to using EikonDesktopDataAPI library in Excel, right? EikonDesktopDataAPI library depends on Eikon application (aka Eikon toolbar). Eikon Excel COM add-in creates its own connection to Eikon platform without relying on Eikon toolbar, but it shares some of the processes with Eikon toolbar. This is why you see Eikon icon in the taskbar when you load Eikon Excel COM add-in and sign in. Although it has never been tested, I don't foresee any problems using EikonDesktopDataAPI in Excel process if Eikon Excel COM add-in is not loaded. But if it is loaded, then all you can do is to try instantiating Eikon COM APIs objects by calling CreateReutersObject function of PLVbaApis.dll. Again this has never been tested, but it is your best bet.

icon clock
10 |1500

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

Click below to post an Idea Post Idea