Alternating Trades.

 

If I do not want to trade long after a buy trade and vice versa is there a function in MT4 that does that? Or will somethin like this work too?

If LastOpenTrade != Op_Buy

Thanks. 

 
You will meed to handle it yourself. This code logic that you wrote will handle it
Reason: