Download MetaTrader 5

Is it possible to remove a manually entered trailing stop in code?

To add comments, please log in or register
NeilG
65
NeilG  

Hi, 

Is it possible to remove a manual trailing stop [originally created by right-clicking on a pending order and adding a trailing stop] in EA code?

Any assistance would be appreciated. 

Thanks,

Neil 

Alain Verleyen
Moderator
32397
Alain Verleyen  
snafu4:

Hi, 

Is it possible to remove a manual trailing stop [originally created by right-clicking on a pending order and adding a trailing stop] in EA code?

Any assistance would be appreciated. 

Thanks,

Neil 

No, you can't manage the "manual trailing stop" by code. You have to create and manage your own trailing stop within your code.
NeilG
65
NeilG  
angevoyageur:
No, you can't manage the "manual trailing stop" by code. You have to create and manage your own trailing stop within your code.


Thank you for the prompt reply.
Daniel Petrovai
440
Daniel Petrovai  
snafu4:

Hi, 

Is it possible to remove a manual trailing stop [originally created by right-clicking on a pending order and adding a trailing stop] in EA code?

Any assistance would be appreciated. 

Thanks,

Neil 


Apparently cancelling the order stop loss also cancel the trailing stop set on that order.

I only tried it manually but you can test it yourself on a demo account. That may open a possibility for you to select the order with OrderSelect() and cancel the stop after that you can manage the order with your EA.

Just a thought. 

To add comments, please log in or register