I have the following code in my strategy, but the TrailStop is executing as soon as a position is entered.
I would like it to start trailing only once break even has been hit, as I have another initial StopLoss that is much tighter.
if ((Position.MarketPosition == MarketPosition.Long)
&& (BEBool == true))
{
SetTrailStop(@"Long", CalculationMode.Ticks, 10, true);
}
BEBool is a boolean set to true once breakeven has been hit. The SetTrailStop() is seemingly ignoring this and sets immediately on entry.

Comment