Replace OrderModify() with a double variable and instead of sending the new value to the server, store it in this double.
Then add additional code to close the order whenever price rises of falls above or below that double value.
Replace OrderModify() with a double variable and instead of sending the new value to the server, store it in this double.
Then add additional code to close the order whenever price rises of falls above or below that double value.
Thank you for reply.
Just to make sure you get what my problem is. I need to store the value of SL as OderStop as I am not going to use OrderModify() anymore where OrderStopLoss() is easly available. If what you just explained is what I m saying, could you please explain with a hint of a code, the double variable part leave the OrderClose().
Also the double variable need to be filtering, Only use it if its value is > than the previous.

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
I want to replace my trailing stop to Virtual as I am about to change to a broker with 50 point stop level, However I completely have no idea where to start, Can someone enlighten me a little bit.
which method to use here?