You can use this code
int ADXPeriod = 14; double ADXMain = iADX(NULL,0,ADXPeriod,PRICE_CLOSE,MODE_MAIN,0); if( ADXMain > 25 ) { // do something }
I assume you use MT4, if you use MT5, the code will be different
Biantoro Kunarto:
I assume you use MT4, if you use MT5, the code will be different
Thank you very much sir for being generous. God Bless you...
I assume you use MT4, if you use MT5, the code will be different

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
Good day to everyone. I want to make an EA based on ADX. I want to ask if how to code using ADX indicator? thank you. I mean what are the necessary parameters? it's like if the ADX 14 is above level 25, it will execute position based on another trend following indicator.
Thank you and God Bless you all.
NIECO P. PAMA