As soon as I enter, I have a trailing stop variable that saves average price - stop loss points (30) and a stop order with same condition.
On next set, I have a condition that checks price is average price + take profit 1 (30) and set the trailing stop variable to current price - stop loss points.
Now, it trails it but it goes up and down 30 points with the price.
If price is at 18000, stop is at 17970. When price goes down to 17970, stop trails down to 17940 instead of stopping at 17970.
Basically, right now, it never hits stop as price never hits price - 30.
How do I make it a trail stop and not go down from the highest trailing stop price?
Thanks

Comment