Discover Refinitiv
MyRefinitiv Refinitiv Perspectives Careers
Created with Sketch.
All APIs Questions & Answers  Register |  Login
Ask a question
  • Questions
  • Tags
  • Badges
  • Unanswered
Search:
  • Home /
  • Eikon COM /
avatar image
Question by 12avi · Jul 22, 2020 at 11:29 AM · eikoneikon-com-apiexcelvbaDownloadcommodities

I am not able to refresh the Refinitv "Download Manager" MS Excel workbook programatically

I'm trying to use your MS Excel Download Manager template to download commodity forecasts automatically. To refresh the file, I can successfully press the " Refresh All Files" vba button and it updates the sheet with the data as intended.

However, when I try and do this same task programmatically, by calling the underlying VBA macro, it doesn’t work.

I get the error message "Please upgrade Thomson Reuters Eikon Excel." which is part of Error message 91 within the "m_syncMgr = CreateSynchronizationMgr" of your VBA Excel Workbook. (please see below)


Please can you provide any advice how refreshing this Refinitiv Workbook can be done automatically and not manually? The underlying data/forecasts are also within Eikon, but they can not be accessed via the Eikon API.


one.png (24.3 KiB)
two.png (20.5 KiB)

People who like this

0 Show 0
Comment
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

3 Replies

  • Sort: 
avatar image
REFINITIV
Best Answer
Answer by Alex Putkov.1 · Jul 30, 2020 at 03:58 PM

Your assumption is incorrect. While the use of the Web Service endpoints in any applications other than Excel is not supported and is strongly discouraged, just like we discourage regarding the capability exposed in the Download Manager spreadsheet as a datafeed, if you'd like to refresh the data in the Download Manager spreadsheet a couple of times a day, I don't see any problems with that.

Now I'm going to take a wild guess about what you're trying to do. I'm guessing you're trying to build some sort of a cron job (a batch file or VBS script or something) that you can assign to the Task Scheduler. This cron job creates an instance of Excel application and opens the Download Manager. Then the VBA code in Workbook_Open procedure will execute and this is how you intend to refresh the data to then save it in another file or some such. The issue you may be running into is that when you use OLE Automation to create an instance of Excel (invoke Excel.Application class), Excel will be launched without any add-ins. In this scenario you need to manage the add-ins in your code. Specifically you need to ensure Eikon Excel add-in is loaded before creating an instance of SynchronizationMgr COM object. If indeed this is what you're trying to implement, here's a couple of previous threads you may want to look at.

https://community.developers.refinitiv.com/questions/41040/eikon-com-addin.html

https://community.developers.refinitiv.com/questions/29464/launch-excel-com-add-in-with-python-win32com.html

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

avatar image
REFINITIV
Answer by Alex Putkov.1 · Jul 22, 2020 at 09:00 PM

Clicking Refresh All Files button in this spreadsheet runs the procedure named Refresh in ThisWorkbook module. Since you were able to update the data by clicking Refresh All Files button, we know the Refresh procedure in ThisWorkbook module executed correctly. This also means CreateSynchronizationMgr function executed successfully and returned an instance of SynchronizationMgr COM object.
I don't think I'm following how you reproduce the issue you've experienced. Did you run Workbook_Open procedure in your screenshot? If yes, for what purpose? What were you trying to achieve? It would be very helpful to know how precisely you reproduce the error. I'm also not following what you mean by "refreshing this Refinitiv Workbook automatically and not manually". If you'd like the workbook to refresh whenever you open the spreadsheet file, just add the call to Refresh procedure into Workbook_Open. If you're looking to do something else, would you mind specifying what it is?

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

avatar image
Answer by 12avi · Jul 30, 2020 at 09:00 AM

Hi Alex,


Thanks for your reply. I wanted to run some code that automated the download from the Excel workbook, instead of manually opening and running the refresh macro. Doing the process manually seems to work, however automating it so the file is opened and the Refresh macro called raises an error.


Upon looking into this further, I’ve unfortunately learned that Refinitv does not want this sort of operation performed with the Download Manager and it was advised not to create such macros/ automation (please see here).

So I assume, the CreateSynchronizationMgr dll function looks for signs the update is being done by automation instead of manually and causes the error to be raised to prevent this. Is this a correct assumption, as I'm only trying to refresh Excel file once/twice a day at most?


Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

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

Watch this question

Add to watch list
Add to your watch list to receive emailed updates for this question. Too many emails? Change your settings >
10 People are following this question.

Related Questions

How do I trigger a VBA macro from within the TR function in Eikon Excel

Downloading fundamental stocks data using API in VBA

How to disable automatic TR data refresh in Excel?

Can I obtain News with the COM API?

VBA - Run and update TR Eikon data

  • Copyright
  • Cookie Policy
  • Privacy Statement
  • Terms of Use
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Alpha
  • App Studio
  • Block Chain
  • Bot Platform
  • Connected Risk APIs
  • DSS
  • Data Fusion
  • Data Model Discovery
  • Datastream
  • Eikon COM
  • Eikon Data APIs
  • Electronic Trading
    • Generic FIX
    • Local Bank Node API
    • Trading API
  • Elektron
    • EMA
    • ETA
    • WebSocket API
  • Intelligent Tagging
  • Legal One
  • Messenger Bot
  • Messenger Side by Side
  • ONESOURCE
    • Indirect Tax
  • Open Calais
  • Open PermID
    • Entity Search
  • Org ID
  • PAM
    • PAM - Logging
  • ProView
  • ProView Internal
  • Product Insight
  • Project Tracking
  • RDMS
  • Refinitiv Data Platform
    • Refinitiv Data Platform Libraries
  • Rose's Space
  • Screening
    • Qual-ID API
    • Screening Deployed
    • Screening Online
    • World-Check One
    • World-Check One Zero Footprint
  • Side by Side Integration API
  • TR Knowledge Graph
  • TREP APIs
    • CAT
    • DACS Station
    • Open DACS
    • RFA
    • UPA
  • TREP Infrastructure
  • TRKD
  • TRTH
  • Thomson One Smart
  • Transactions
    • REDI API
  • Velocity Analytics
  • Wealth Management Web Services
  • Workspace SDK
    • Element Framework
    • Grid
  • World-Check Data File
  • 中文论坛
  • Explore
  • Tags
  • Questions
  • Badges