OnTimer

 
How can you force an EA to run only OnTimer in mql4 and ignore any incoming broker ticks?
 
BHC:
How can you force an EA to run only OnTimer in mql4 and ignore any incoming broker ticks?

Probably by renaming the start() to OnTimer()
 
BHC:
How can you force an EA to run only OnTimer in mql4 and ignore any incoming broker ticks?

Don't use a start() or OnTick() function, or do this :

void OnTick()
  {
   return;
  }
 
angevoyageur:

Don't use a start() or OnTick() function, or do this :


I made this code for testing but OnTimer dont work, with OnTick is ale rigt. Would be the problem that broker doesnt support this function?


<CODE REMOVED>

 
cza:

I made this code for testing but OnTimer dont work, with OnTick is ale rigt. Would be the problem that broker doesnt support this function?


<CODE REMOVED>

I removed your code . . . .


Please edit your post above and re-insert your code using the SRC button . . . please use the SRC button to post code: How to use the SRC button.

To edit your post . . .

 
RaptorUK:

I removed your code . . . .


Please edit your post above and re-insert your code using the SRC button . . . please use the SRC button to post code: How to use the SRC button.

To edit your post . . .




ok, but you could connect some answer for my question too :))
 
cza:

ok, but you could connect some answer for my question too :))
Of course, please post your code.
 
cza:

ok, but you could connect some answer for my question too :))
OK ? so do as I asked . . . and I'll look at helping.
 
cza:

I made this code for testing but OnTimer dont work


What? You sure use build 600? This surely runs on my box:


// expert - testtimer

#property strict

int OnInit()
{
        EventSetTimer(1);
        return(INIT_SUCCEEDED);
}
void OnDeinit(const int reason)
{
        EventKillTimer();
}
void OnTimer()
{
        Print("happy timer, tick, tick...");
}
Reason: