Forums ProRealTime English forum ProOrder support Trailing stop moving the wrong way Reply To: Trailing stop moving the wrong way

#131486

You haven’t got the lines below in your code, but they are in Nicolas code at lines 43 to 46

Well spotted – that could be it. Probably got left out of the copy and paste somehow. How many algos have i got with that flaw I wonder…

TRADEPRICE is an average af the entry price of all positions

That’s interesting. Cumulateorders is false, so I don’t actually need that. Can I just change TRADEPRICE to CLOSE or CLOSE[1]?