RFA Exception Handler - Access Violation / Excel Vba Eikon
I implemented a VBA script which collects all options in a Chain (e.g. "0#ABBN*.EX") via
the AdfinXRtLib.AdxRtChain object. Next the script queries data for all options the chain via
AdfinXRtLib.AdxRtList (~300 RICS, 10 FID). So fare the script works as intended.
However, if this is done in a loop of ~100+ iterations excel crashes with the below error message.
Do you have an idea what goes wrong?
(In every loop new API objects are initialize, I have no other COM add-ins active.
I'm using AdfinX Real Time 6.0 Library.)
RFA Exception Handler
Application: EXCEL
Process Id: 0x330C
Thread Id: 0x47C0
File: ..\..\..\Common\Support\OS\Impl\Thread.cpp
Line: 51
Problem:
Exception "Access Violation" (0xC0000005) occured at 0x52BBF608: memory at 0x00000000 cannot be read
Best Answer
-
@Zhenya Kovalyov the samplefile does not trigger an error. I assume the problem is triggered by creating a new AdxRtLists for each request. If I reuse the same object for each request the error does not trigger.
Maybe, I should keep one AdxRtLists object alive and register/unregister new items in each request.?
I do not request multiple instruments at the same time because I need the results for further calculations which should not be based on outdated market prices. Furthermore the sequence and time of each instrument is unknown.
0
Answers
-
Could you upload a sample Excel file with this issue? Thanks
1 -
Are these calls sequential, i.e. you are creating a new request after receiving a response for the previous iteration?
1 -
I created a simplified xslm file where the exeption still occures. Simply run the sub test. The script crashes between i=250 and i=300. Thanks for your support.
Yes, it creates a new request with each iteration.
0 -
@sascha.arican, is there a reason why you request the instruments with multiple AdxRtLists instead of running a single request for multiple instruments?
In the meantime, could you open this file adxrtlist-samplexlsm.zip run the following sequence:
1. Create()
2. Request()
and after "DONE" in the immediate window
3. Dispose()
Does it trigger an error?
0 -
Well, it looks like that the error is triggered when you destroy the object rather than create it. In the sample file I decouple the event handler routine from disposing of the created objects, and it works fine.
Reusing the object is also a possibility, make sure that you do it correctly by executing
mAdxRtList.StopUpdates
mAdxRtList.CloseAllLinks
mAdxRtList.UnregisterAllItems1
Categories
- All Categories
- 6 AHS
- 37 Alpha
- 161 App Studio
- 4 Block Chain
- 4 Bot Platform
- 16 Connected Risk APIs
- 47 Data Fusion
- 30 Data Model Discovery
- 608 Datastream
- 1.3K DSS
- 577 Eikon COM
- 4.9K Eikon Data APIs
- 7 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- Trading API
- 2.7K Elektron
- 1.3K EMA
- 236 ETA
- 519 WebSocket API
- 33 FX Venues
- 10 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 20 Messenger Bot
- 2 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 59 Open Calais
- 264 Open PermID
- 39 Entity Search
- 2 Org ID
- PAM
- PAM - Logging
- 8.4K Private Comments
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 20 RDMS
- 1.4K Refinitiv Data Platform
- 367 Refinitiv Data Platform Libraries
- 3 Refinitiv Due Diligence
- LSEG Due Diligence Portal API
- 3 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.1K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 10 World-Check Customer Risk Screener
- 990 World-Check One
- 44 World-Check One Zero Footprint
- 45 Side by Side Integration API
- Test Space
- 3 Thomson One Smart
- 1.2K TR Internal
- Global Hackathon 2015
- 2 Specialists Who Code
- 10 TR Knowledge Graph
- 150 Transactions
- 142 REDI API
- 1.7K TREP APIs
- 4 CAT
- 21 DACS Station
- 117 Open DACS
- 1.1K RFA
- 103 UPA
- 172 TREP Infrastructure
- 224 TRKD
- 886 TRTH
- 5 Velocity Analytics
- 5 Wealth Management Web Services
- 59 Workspace SDK
- 9 Element Framework
- 5 Grid
- 13 World-Check Data File
- Yield Book Analytics
- 46 中文论坛