I try to use multi instruments strategy in Strategy Analyzer(NT v 7.0.0.15)
Why doesn't work code:
if (Positions[0].GetProfitLoss(Closes[0][0] ,PerformanceUnit.Points) + Positions[1].GetProfitLoss(Closes[1][0] ,PerformanceUnit.Points) > 5 )
{
ExitLong( 0 , 1 , "EndOfLongP" , "BUY MSFT");
ExitShort( 1 , 1 , "EndOfShortP" , "SELL AAPL");
}
although another simple code works correctly:
ExitLong( 0 , 1 , "EndOfLongP" , "BUY MSFT");
ExitShort( 1 , 1 , "EndOfShortP" , "SELL AAPL");
Comment