MQL4 code error - Is not expert and cannot be executed

 

Hi,


I created a sample EA but it keeps getting the error "... is not expert and cannot be executed.".

Any thoughts?


Thanks,


Young

 
1004:

I created a sample EA but it keeps getting the error "... is not expert and cannot be executed.".

Any thoughts?

Remove the OnStart(). Use start instead.

Make sure that the expert is within expert folder instead of Scripts or Indicator.

 
1004:

Hi,


I created a sample EA but it keeps getting the error "... is not expert and cannot be executed.".

Any thoughts?


Thanks,


Young

Wlecome to mql4.com forum,

You can also check that you don't have a line like :

#property show_inputs

If yes, you can remove it, compile and try again.

 
1004:

Hi,


I created a sample EA but it keeps getting the error "... is not expert and cannot be executed.".

Any thoughts?


Thanks,


Young


Makes it easier to get help if you post the code. Else, we are just guessing.
 
I had similar error caused by using script that implements OnTick() function, which confused the compiler with EA OnTick() function, rendering the program as non EA. In case you are including script, remove OnTick() on script and the EA will work.