How can I solve this problem?

4 views (last 30 days)
Simon Blum
Simon Blum on 22 Jul 2016
Answered: Yair Altman on 10 Jan 2018
>> ib=ibtws('',7496)
Error using feval
Server Creation Failed: Die angegebene Prozedur wurde nicht gefunden.
Error in actxserver (line 86)
h=feval(['COM.' convertedProgID], 'server', machinename, interface);
Error in ibtws
---------------------------------------------------------------------------------------------------- MATLAB Version: 9.0.0.341360 (R2016a)
MATLAB License Number: STUDENT
Operating System: Microsoft Windows 10 Pro Version 10.0 (Build 10586)
Java Version: Java 1.7.0_60-b19 with Oracle Corporation Java HotSpot™ 64-Bit Server VM mixed mode
----------------------------------------------------------------------------------------------------
I installed all requirements.
Further I checked if the ActiveX controller is insatalled and is working. Everything all right.
I used the following tutorial to set the right settings: http://www.youtube.com/watch?v=Q6OVl9MMlcs
Then I checked with IB API support. Unforunately they couldn't help me. They ment that I have done everything right.
So I am runnign out of ideas... Can please someone help me?
Best Regards
Simon
  12 Comments
Simon Blum
Simon Blum on 25 Jul 2016
Does Matlab IB TWS API run on windows 10? Is there anybody using it?
Diego Ochoa
Diego Ochoa on 31 Jul 2016
Hi simon. I'm having the same problem and I'm starting to believe that 64bit version of windows does not work well with IBTWS that was apparently written for 32 bit OS. It seems o be looking for a procedure or component in a folder that does not belong to the 64 bit version or is named differently. Already tried the same steps. Installed and un-installed 32 and 64 bit versions of both Matlab and TWS. I have other computer that runs on Windows 10 x86 version. Connection goes smoothly, but is an old machine and does not have enough memory to handle Matlab and TWS at the same time. I bought a New machine that comes with Windows10 64 bit pre installed and I've spent the whole weekend trying to solve it. ¿Have you managed to solve this?. I'm out of options here.

Sign in to comment.

Answers (3)

ivan Kiriyanov
ivan Kiriyanov on 25 Jan 2017
Here's the solution for IB API ver 9.71. It appears that Matlab does not work with later versions of API.
1. Uninstall the API component by navigating to Control Panel -> Program and Features 2. Locate and delete the following files if they are still present:
C:\Windows\System32(SysWOW64)\TwsSocketClient.dll C:\Windows\System32(SysWOW64)\MsFlxgrd.ocx C:\Windows\ddedll.dll
3. Restart your computer. 4. Install the Microsoft Visual C++ 2005 SP1 Redistributable Package (x86) http://www.microsoft.com/en-us/download/details.aspx?id=5638 5. Install the Microsoft Visual J# 2.0 Redistributable Package. http://www.microsoft.com/en-us/download/details.aspx?id=4712
If the problem still persists, you may have to register the Tws.ocx file manually. It is essential that you run CMD or command in Administrator, even though you login as local administrator. Please follow the below steps:
1. Copy Tws.ocx (C:\TWS API\bin\ActiveX\ to the following directory: C:\Windows\System32(SysWOW64)\ 2. Click the Search Windows icon (Magnifier glass) and in the Search area, type "cmd” 3. Right click the "Command Prompt" banner, and select "Run as Administrator" 4. At the command prompt, enter: %systemroot%\System32(SysWOW64)\regsvr32.exe Tws.ocx 5. This should successfully register your Tws.ocx.
  1 Comment
Daniel Matteson
Daniel Matteson on 23 Mar 2017
ivan, i cant find the tws.ocx files anywhere.... I performed steps 1-5 but when i re-install the API, i get the same error. Do you have any other suggestions or would you mind educating me regarding the TWS.ocx files? Thank you, Daniel Matteson

Sign in to comment.


Mirko
Mirko on 27 Oct 2017
I follow the 1st 3 steps. But 4th step is unable to execute in command prompt. kindly give some ideas.
Copy Tws.ocx (C:\TWS API\bin\ActiveX\ to the following directory: C:\Windows\System32(SysWOW64)\ 2. Click the Search Windows icon (Magnifier glass) and in the Search area, type "cmd” 3. Right click the "Command Prompt" banner, and select "Run as Administrator" 4. At the command prompt, enter: %systemroot%\System32(SysWOW64)\regsvr32.exe Tws.ocx

Yair Altman
Yair Altman on 10 Jan 2018
You can also try the suggestions here: https://www.mathworks.com/matlabcentral/answers/111625-trading-toolbox-connecting-to-interactive-broker
(and of course, you are always welcome to try my Java-based IB-Matlab connector, which does not use ActiveX/COM)

Categories

Find more on Startup and Shutdown in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!