Expert Advisors: Multicurrency OnTick (string symbol) event handler - page 4

 
nra_:
I realise that OnDeinit in the EA should not come to OnDeinit, but this is ideal. Are you sure that During 15 hours of your test, OnInit was called 1 time in the Expert Advisor?

Yes. Why should it be otherwise?

It is an EA, it has no reinitialisations without user participation (change of chart, parameters, recompilation).

 

Good, although I'd check to see if that's the case in reality. I'll put the test on my laptop now. In the evening we will see the result. My EA exports ticks to an external module in a similar way, I would like to understand how robust the OnChartEvent solution is.

PS. Do you have custom symbols in the market overview at the time of the test?

 
nra_:

Good, although I'd check to see if that's the case in reality. I'll put the test on my laptop now. In the evening we will see the result. My EA exports ticks to an external module in a similar way, I would like to understand how stable the OnChartEvent solution is.

PS. Do you have custom symbols in the market overview at the time of the test?

There are no custom ones.

But apparently the problem is not reproduced for everyone. I've given up on spies for now.

 
Did the connection break during the test?
 
nra_:
Did the connection break during the test?

No, there are no looses in the connection log.

 

From the include file OnTick(string symbol).mqh:

//+------------------------------------------------------------------+
//| Expert tick function|
//|| Used exclusively for use in the tester ||
//+------------------------------------------------------------------+
void OnTick()
  {
   if(_testing_)
     {
      for(int i=0; i<_symbols_total_; i++)
        {
         string __symbol__=_symbol_[i];
         if(MathAbs(GlobalVariableGet(__symbol__+"_flag")-2)<0.1)
           {
            GlobalVariableSet(__symbol__+"_flag",1);
            OnTick(__symbol__);
           }
        }
     }
  }
//+------------------------------------------------------------------+

Do I understand correctly that this is not a full-fledged multicurrency tester anyway? The check happens ONLY when a tick arrives on the main chart, it just checks if other symbols have changed by then?