Datafeed toolbox - IQFeed fails with a callback error?

Hi,
I have just started using MATLAB Datafeed toolbox to connect to IQFeed. My script is taken from examples in help.
c = iqf('REMOVED','REMOVED');
sec = 'IBM';
fromdate = now-0.05; % beginning of date range for intraday data
% (approximately one hour ago)
todate = now; % ending of date range for intraday data (current time today)
timeseries(c,sec,{fromdate,todate})
close(c);
However I get following error on execution.
Warning: Error occurred while executing delegate callback:
Message: Cannot access a disposed object.
Object name: 'System.Net.Sockets.Socket'.
Source: System
HelpLink:
I have tried with history and it gives the same error.
history(c,'GOOG',5)
Any help is appreciated.

 채택된 답변

Sean de Wolski
Sean de Wolski 2014년 11월 12일
Possibly a path issue, give this a try. If it doesn't work, then call tech support:
restoredefaultpath
rehash toolboxcache

댓글 수: 1

Thanks Sean,
I think path was the issue. It works now.
Btw, I raised with tech support later and here is the response. Thought it might be helpful for someone else.
=====
"I investigated on this and found that IQFeed is designed to work with applications that are "closed". For example, a UI that works with IQFeed will open the connection and leave it open until the UI is closed. The connection is never closed. Since, MATLAB allows dynamic interaction from the command line, you are able to attempt to open and close connections to IQFeed in the same session. This unfortunately leads to socket warnings in some cases.
To work around this issue ideally, you should avoid closing the IQFeed connection once it has been made from a MATLAB session."
=====

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 Workspace Variables and MAT Files에 대해 자세히 알아보기

질문:

2014년 11월 12일

댓글:

2014년 11월 12일

Community Treasure Hunt

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

Start Hunting!

Translated by