I am going to be using Google Translate to translate your message.
In the managed approach, it is designed so that any Exit order will be ignored if an entry does not exist. So if you call ExitLong and the strategic position is flat, the ExitLong order will be ignored.
You will need to add Prints to the strategy to find what's wrong. This part does not seem right to me, but this is just an assumption as I don't have full knowledge of the code:
ExitLong("Exitlong5", ""); // Condition set 5.2 condicion de salida de la estrategia fallida. if ( EMA(SMALAJC)[0] + SMA(SMALAJC)[1] < EMA(SMALAJC)[1] + SMA(SMALAJC)[0] && Position.GetProfitLoss(Close[0], PerformanceUnit.Currency) >= (stop / salidasExitLargoCON)) { ExitLong("Exitlong5", "");
Best regards.
Leave a comment: