My next question I want to get a trailing stop loss based on a "breakeven" price point using the losses calculation and have come with the following:
For each position will use the last opened order as a reference point and then I want to check if the current open trades profit is more than the losses and record the current price then I want to add 15 pips for a profit above breakeven

Im not sure if that is the right way or if using a formula for the current market price less open price of the last order in loop
Lets say the last opened order as a reference point (ie 0 pips) and my breakeven condition is at 20 pips below that order and I want 15 pips profit from there
so the trailing stop will need to start from an offset from the open price 35 pips

Am I on the right track or is there another way to do it?



