Using Sell with Or but second part not working

I have tried for some time to work this out on my own, but without success unfortunately. I am turning to the forum for help. The second part of my sell coding below does not work and all exits are based on the first part. I suspect it may have something to do with the word "buy" in the second part. I know that using ApplyStop does not by itself trigger a sell signal. Thanks in advance for any help.

Sell = Close > MA(C,stopma) OR Sell=BarsSince(Buy)==10;

You don’t OR the assignments
And for time based stop you better use ApplyStop stoptypeNbar

Thank you, Tomasz. The code below worked for me.

ApplyStop(stopTypeNbar, stopModeBars, stopbars);

Sell = 0 OR C > MA(C,stopma);

This topic was automatically closed 100 days after the last reply. New replies are no longer allowed.