Login Page - Create Account

Support Board


Date/Time: Sun, 19 May 2024 06:52:41 +0000



Post From: ACSIL: disable autotrading once a DailyProfitLoss target is reached

[2015-10-05 21:47:40]
User44052 - Posts: 34
In an ACSIL auto-trading strategy, is it possible to programmatically disable auto-trading once a target DailyProfitLoss has been hit?

The support board has answers for doing this when using spreadsheet trading, but I can't find an equivalent for ACSIL.

I'm trying this but it doesn't seem to work.

  sc.MaintainTradeStatisticsAndTradesData = true;

  s_SCPositionData myPositionData;
  sc.GetTradePosition(myPositionData);

if ( myPositionData.DailyProfitLoss >= 10 )
{
break
}