Bots not working on .NET 6
Bots not working on .NET 6
07 Jul 2022, 12:01
Hi, I am using cTrader on windows 10 with .NET 6.0.301 SDK and runtime installed. However, whenever I build a bot for .NET 6, it builds the .algo file but cTrader cannot run it. No errors or messages show in the log, nothing happens at all. If we switch to .NET 4, everything works as usual, as if cTrader couldn't use the .NET 6 framework. What could be the issue? Thanks for help
Replies
strakmi
07 Jul 2022, 13:23
( Updated at: 07 Jul 2022, 13:31 )
Hi Panagiotis,
I haven't even started making custom cbots or indicators on this pc, the issue already happens with the Sample cbots included in cTrader.
I would start a clean install of spotware ctrader, log in, go straight to the automate tab and set the target framework to .Net 6. I can then build any of the sample cbots, and get the "build succeeded" message. The .algo file appears in the Robots folder as usual. However, once I add an instance of the bot to a symbol and start it, nothing happens, the cTrader log doesn't show the usual message that an instance was added and no code is executed. Stopping the cBot also produces no logs. I have tried building the bot from terminal using "dotnet build - - configuration Release" command with the same result.
However, if I repeat the same steps while setting the build target framework in cTrader to .Net 4.x, everything works as it should and the cbots run as usual.
I have reinstalled the .NET 6 framework, so it is definitely on the os, but maybe cTrader can't access it to run the bots for some reason? I am running windows 10 pro version 21H2 on AMD Ryzen 7 2700.
Thank you for your help.
@strakmi
PanagiotisCharalampous
08 Jul 2022, 11:27
Hi strakmi,
Any chance you can record a video demonstrating all this so that I can forward it to the product team to check?
Best Regards,
Panagiotis
Join us on Telegram and Facebook
@PanagiotisCharalampous
ctid2032775
18 Jul 2022, 19:35
Hi,
sounds similar to the issue I reported (Issue with cBot using target framework .NET 6)...
I am curious about the results of the checks.
BR,
Christian
@ctid2032775
ctid1779370
19 Jun 2024, 02:14
( Updated at: 19 Jun 2024, 04:58 )
RE: Bots not working on .NET 6
Did you solve this? It's the exact problem i am having.
@ctid1779370
PanagiotisCharalampous
07 Jul 2022, 12:44
Hi strakmi,
Can you share your cBot code and exact steps that reproduce the problem?
Best Regards,
Panagiotis
Join us on Telegram and Facebook
@PanagiotisCharalampous