Download MetaTrader 5
To add comments, please log in or register
Enable MQL5 Storage to store your source codes. It is free!
sdoppke
70
sdoppke 2015.08.24 22:27 

Hi there I have searched and cannot find the exact answer on how to incorporate ADX into my trade logic.


I am trying to only allow my buy order be opened only if the current 8 period ADX value is > 22.  I thought it would look like so, but not luck.  Any help would be greatly appreciated.


if (iADX(NULL, 0, 8, PRICE_CLOSE, MODE_MAIN, 0) > 22;


SD

Keith Watford
Moderator
7952
Keith Watford 2015.08.24 22:48  
if (iADX(NULL, 0, 8, PRICE_CLOSE, MODE_MAIN, 0) > 22)
  {
  //code
  }
something like that
sdoppke
70
sdoppke 2015.08.25 14:48  
That was it, I really appreciate it! 
/
To add comments, please log in or register