Hi, you can move SL by ATR with this code:
double atr = iATR(NULL,0,14,0);
double SL = SL - (2*atr);
Tomas Michalek:
Hi, you can move SL by ATR with this code:
double atr = iATR(NULL,0,14,0);
double SL = SL - (2*atr);
I am not sure what you are trying to do there. You have not assigned an initial value to SL and then you are subtracting 2*atr. ?????
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
HI.
I want to build an expert advisor that will automatically set my SL to 2xATR of the position I'm in
Tried a few things but they didn't work
Any kind of help is much appreciated