an old ea, just for play around with setting, but cant backtest, can anyone fix it?

 

sharing is caring...

 
claymore898:

sharing is caring...

First of all, update the format/names of init(), deinit() and start() according to https://docs.mql4.com/basis/function/events.

Next, set this flag to false:

extern bool    TradingSuspended=true;

With these done, you'll see something going on when you backtest.

Event Handling Functions - Functions - Language Basics - MQL4 Reference
Event Handling Functions - Functions - Language Basics - MQL4 Reference
  • docs.mql4.com
The MQL4 language provides processing of some predefined events. Functions for handling these events must be defined in a MQL4 program; function name, return type, composition of parameters (if there are any) and their types must strictly conform to the description of the event handler function. The event handler of the client terminal...