What am I doing wrong here with iMACD

 

Hi,


I am new to MT4 and trying to get some code working. I am not sure what I am doing wrong.  I am gettting the error iMACD - wrong parameter count.


 Attached is the screenshot of the code.MACD

 
  1. To post code copy and paste it by using the code button </> or Alt+1
  2. Do you know how many MACD EAs already exist? Search for them (top right the lens)!
  3. There is one MACD sample that is part of the standard delivery of MT$ (and MT5)!!
  4. You'd better use one of them and amend them - if you have new ideas!
  5. MT4 belongs to the thread at the bottom!
 
I am new to MT4 and trying to get some code working. I am not sure what I am doing wrong.  I am gettting the error iMACD - wrong parameter count.

Install MT4 if you want to write MT4 code. Your screenshot shows that you are using MT5. iMACD() has different parameters in MQL5 than MQL4.

 
Thanks Anthony and Carl for the suggestions. I will check if it has to do with MQL4 vs MQL5.
Reason: