Increase speed of closing positions by bot
Created at 26 Apr 2024, 21:40
CH
Increase speed of closing positions by bot
26 Apr 2024, 21:40
Dear Guys,
When using:
foreach (var pos in Positions) ClosePosition(pos);
the positions are closed visibly slower than when using built-in Close button in Positions tab (lower right part of the interface). When I have 4-5 position, closing them with cBot takes 2-3x more time than using built-in button.
Is there a way to increase the speed? I am not familiar with async functions, maybe I should look there?
Thanks, Chris
PanagiotisCharalampous
27 Apr 2024, 08:09
Hi there,
Use ClosePositionAsync() instead
Best regards,
Panagiotis
@PanagiotisCharalampous