Can you please send me the Excel VBA code which execute a "refresh worksheet" in Excel ? (regard...

...ing the Thomson Reuters Eikon Excel data).
This is for a client, thank you for your prompt answer.
Best Answer
-
There are two sets of macros that can be used to refresh Eikon Excel worksheet functions.
PLxxxxEventHandler macros have existed since the first version of Eikon. They are asynchronous and take no arguments or parameters. The macros are behind the Refresh commands in Thomson Reuters ribbon and refresh both Eikon Excel and TF functions. The four macros are:
1 - Application.Run "PLRefreshAllEventHandler" to refresh functions in all open workbooks
2 - Application.Run "PLRefreshWorkbookEventHandler" to refresh functions in the current workbook
3 - Application.Run "PLRefreshWorksheetEventHandler" to refresh functions in the current worksheet
4 - Application.Run "PLRefreshSelectionEventHandler" to refresh functions in the selected range
From Eikon/ Eikon - Microsoft Office 4.0.23 some new Refresh macros are available, specifically to provide synchronous refresh method. These are for the power users of Eikon - Microsoft Office utilizing VBA. The Refresh commands allow for synchronous refresh to occur (one line of VBA code needs to finish executing before the next line can begin). Note they do not refresh TF functions. These new commands are:
1 - Application.Run "EikonRefreshSelection"
2 - Application.Run "EikonRefreshWorksheet"
3 - Application.Run "EikonRefreshWorkbook"
4 - Application.Run "EikonRefreshAll"
The first two (optional) parameters for all 4 macros are waitForRefresh(boolean) & timeout, e.g.
Application.Run "EikonRefreshSelection", True, 3000 or Application.Run "EikonRefreshSelection", CBool(Sheet1.Range("A1")), CLng(Sheet1.Range("A2"))
If waitForRefresh is True, code will continue after the timeout in milliseconds even if the refresh isn't done. Both parameters are optional - the waitForRefresh default is true & timeout default is 30000 (30 seconds).
1 - EikonRefreshSelection takes a third optional parameter rangeToRefresh. This is an address (short or external) of the range to refresh.
2 - EikonRefreshWorksheet takes a third optional parameter worksheetToRefresh. This is the name of the worksheet to refresh. It can be in "[Book1]Sheet1" format to refresh a sheet in a workbook that isn't in the foreground. Or just "Sheet1" which will look for the sheet in the ActiveWorkbook.
3 - EikonRefreshWorkbook takes a third optional parameter workbookToRefresh. This is the name of the workbook to refresh.
All 4 macros will return the number of functions refreshed when all completed or timed out when waitForRefresh is true.
Both sets of macros (PLxxxEventHandler and EikonRefreshxxxx) do not require any references to any dlls.
As a result, Eikon - Microsoft Office now provides one Refresh capability that will refresh all functions within a workbook that are part of both the data execution module (TR/Rdata functions) and Backwards Compatibility module (TF functions).
0
Categories
- All Categories
- 3 Polls
- 6 AHS
- 36 Alpha
- 166 App Studio
- 6 Block Chain
- 4 Bot Platform
- 18 Connected Risk APIs
- 47 Data Fusion
- 34 Data Model Discovery
- 685 Datastream
- 1.4K DSS
- 615 Eikon COM
- 5.2K Eikon Data APIs
- 10 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- 3 Trading API
- 2.9K Elektron
- 1.4K EMA
- 252 ETA
- 556 WebSocket API
- 38 FX Venues
- 14 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 23 Messenger Bot
- 3 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 60 Open Calais
- 275 Open PermID
- 44 Entity Search
- 2 Org ID
- 1 PAM
- PAM - Logging
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 22 RDMS
- 1.9K Refinitiv Data Platform
- 652 Refinitiv Data Platform Libraries
- 4 LSEG Due Diligence
- LSEG Due Diligence Portal API
- 4 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.2K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 12 World-Check Customer Risk Screener
- 1K World-Check One
- 46 World-Check One Zero Footprint
- 45 Side by Side Integration API
- 2 Test Space
- 3 Thomson One Smart
- 10 TR Knowledge Graph
- 151 Transactions
- 143 REDI API
- 1.8K TREP APIs
- 4 CAT
- 27 DACS Station
- 121 Open DACS
- 1.1K RFA
- 104 UPA
- 193 TREP Infrastructure
- 228 TRKD
- 917 TRTH
- 5 Velocity Analytics
- 9 Wealth Management Web Services
- 90 Workspace SDK
- 11 Element Framework
- 5 Grid
- 18 World-Check Data File
- 1 Yield Book Analytics
- 46 中文论坛