Trouble with MarketData.GetSeries()
Trouble with MarketData.GetSeries()
04 Sep 2017, 21:59
Hello guys,
I am having trouble with MarketData.GetSeries(). I have a list of symbols that I need to get market series data from for further calculations, but my bot sometimes gets stuck getting the series for a random symbol. The bot itself runs fine 99% of the time, that is why I think the error is not at my end.
Inside OnStart function I put market series data into an array like so:
series[i] = MarketData.GetSeries(Symbols[i], TimeFrame);
and this is where the bot gets stuck. The symbols that cause this problem are always the ones that are closed for trading at that time. I can restart the bot, restart Ctrader, ... but nothing helps. The bot continues when trading for that symbol starts.
I hope someone has an idea how to get around this.
Cheers
Spotware
05 Sep 2017, 09:07
Dear Trader,
Thanks for reporting this issue to us. We tried reproducing the described behavior following your description but we couldn't. Market series for several symbols that are closed for trading seems to be working fine. Can you please provide us with the cBot and a specific symbol that reproduces the error. Please also inform us which broker do you use so that we can use the exact same environment to reproduce the problem.
Best Regards,
cTrader Team
@Spotware