Old tick error disables EA

 

Hi,

I have searched the forum for this problem but found no workable solution: When my EA (on a live account) encounters an 'Old Tick' error (for closing all market and pending orders at a specific time),the EA simply stops working and does not re-try until I manually intervene(typicaly several hrs later).I close orders in this manner:

void TimeExit(int CloseHour)
{
int tot = OrdersTotal();
for (int cny = 0 ; cny < tot ; cny++)
{
OrderSelect(cny,SELECT_BY_POS,MODE_TRADES);
bool otherdayC,fridayC;
otherdayC=false;
fridayC=false;
if ((TimeHour(TimeCurrent()==CloseHour))&& (TimeDayOfWeek(TimeCurrent()<5))) otherdayC=true;
if ((TimeHour(TimeCurrent()==(CloseHour-1)))&& (TimeDayOfWeek(TimeCurrent()==5))) fridayC=true;
if ((otherdayC)||(fridayC))
{
if(((OrderType()==OP_BUY)|| (OrderType()==OP_SELL))&& (OrderSymbol() == Symbol()))
OrderClose(OrderTicket(),OrderLots(),Bid,Slippage, Green);
if(((OrderType()==OP_BUYSTOP)|| (OrderType()==OP_SELLSTOP))&& (OrderSymbol() == Symbol()))
OrderDelete(OrderTicket());

}
}
}

I have experienced this problem with other EA as well so do not think it is related to my code per se, problem is that EA stops working after it encounters Old tick, which according to posts I have read should not happen.

Please assist.

Regards,

spanero

 

have looksee at this thread '"OLD TICK" error message on JOURNAL' which has links and ideas...

 
fbj wrote >>

have looksee at this thread '"OLD TICK" error message on JOURNAL' which has links and ideas...

I searched the forum for a long time with no solution. Moderator says EA 'should' work despite Old Tick error but it isn't,as the other user has found-:(

 

what can I say... the MetaQuotes people made their comments in that thread. Unable to offer more help.

will have looksee more, but having not experienced myself like you have am at loss - maybe others may offer further enlightenment ;)

 
fbj wrote >>

what can I say... the MetaQuotes people made their comments in that thread. Unable to offer more help.

will have looksee more, but having not experienced myself like you have am at loss - maybe others may offer further enlightenment ;)

Can't help but can confirm, despite what the MetaQuotes people say "Old tick" did shut my Ea down, had to remove and re-install to get it working again,

could be dangerous to yur account if it happens in the wee small hours of the night. Only happened once so I haven't thought about it since.

Just thinking... it might be an issue that is related to Old Tick .....but not caused by it so we see the log error but it is un-related to what shut the ea down.

Keith

 

I run the FapTurbo 24/7 and seem to remember seeing mention of 'old tick' in logs, but dumbly not think any more of it. I just did search in complete install tree for text: "old tick" and "Old Tick" but not find what looking for...

Basically, my pc just kept chugging along. It only stops when it decides to go belly up due to a mysterious h/w issue or Windoz BSOD events - lol

I always restart once a week + do the check disk's jiggy jiggy + use JkDefrag (got it set so kicks off whenever screen saver timer matures) - totally awesome bit of s/w - completely interruptable. It maps onto Win's basic toolset so is very safe - but does very much better job.

You people ever have power failures?

I do and so got self an APC Back-UPS CS 650 offa ebuyer.com - cheaper ones abound but APC are some would say, the industry standard. Not expensive considering we talking about open trades!!!

(finally choose it due to Amazon.co.uk buyer reviews - one lived in Scottish highlands - not noted for constant on power state! He gave a total rave and long review... I was S.O.L.D, so just needed to source a good price for the UPS - eBuyer was very good and free next day courier delivery - no brainer ;])

Trouble is, like you I sleep sometimes ;) and needed a power off alarm - they too are available on web. But I cheapo and not want pay tens of gbp's so got out my Maplins catalog and having the 'idea'... eventually homed in on a mains powered relay. That combined with a LOUD 9v buzzer + good 9v battery + trusty soldering iron... made up a power off alarm. All for under 5gbp. Anyway... was fun learning required HOWTO's/concepts of the project.

Works a treat - all very heath robinson but it shouts if flip the socket switch off and the UPS gives almost 20mins to do whatever with the pc/any open trades.

Man... pre-alarm,UPS, I woke up to dark/cold house at 06.00 and the wall clock said 01.00!!! Was totally blown away when finally realized that their could have been trades open - man... total darkness and being a confirmed ludite, not have mobile (sad or what;) but... did have old phone that connects directly to line = no transformers needed so power comes from the line alone. Got some candles going and with burning candle wax dripping everywhere found my brokers' folder and got back to the phone and 'made the call' to London/Alpari...

That same day [after about 10hrs brownout] I order UPS [next day free delivery;] and then realize it not gonna wake me up so then got idea about alarm.

.

Please excuse my ramble, but is for sure a frightening experience (am not wealth... yet!) and maybe my drone will get others to consider making 'contingency' plans... NOW :o)

 
fbj wrote >>

I run the FapTurbo 24/7 and seem to remember seeing mention of 'old tick' in logs, but dumbly not think any more of it. I just did search in complete install tree for text: "old tick" and "Old Tick" but not find what looking for...

Basically, my pc just kept chugging along. It only stops when it decides to go belly up due to a mysterious h/w issue or Windoz BSOD events - lol

I always restart once a week + do the check disk's jiggy jiggy + use JkDefrag (got it set so kicks off whenever screen saver timer matures) - totally awesome bit of s/w - completely interruptable. It maps onto Win's basic toolset so is very safe - but does very much better job.

You people ever have power failures?

I do and so got self an APC Back-UPS CS 650 offa ebuyer.com - cheaper ones abound but APC are some would say, the industry standard. Not expensive considering we talking about open trades!!!

(finally choose it due to Amazon.co.uk buyer reviews - one lived in Scottish highlands - not noted for constant on power state! He gave a total rave and long review... I was S.O.L.D, so just needed to source a good price for the UPS - eBuyer was very good and free next day courier delivery - no brainer ;])

Trouble is, like you I sleep sometimes ;) and needed a power off alarm - they too are available on web. But I cheapo and not want pay tens of gbp's so got out my Maplins catalog and having the 'idea'... eventually homed in on a mains powered relay. That combined with a LOUD 9v buzzer + good 9v battery + trusty soldering iron... made up a power off alarm. All for under 5gbp. Anyway... was fun learning required HOWTO's/concepts of the project.

Works a treat - all very heath robinson but it shouts if flip the socket switch off and the UPS gives almost 20mins to do whatever with the pc/any open trades.

Man... pre-alarm,UPS, I woke up to dark/cold house at 06.00 and the wall clock said 01.00!!! Was totally blown away when finally realized that their could have been trades open - man... total darkness and being a confirmed ludite, not have mobile (sad or what;) but... did have old phone that connects directly to line = no transformers needed so power comes from the line alone. Got some candles going and with burning candle wax dripping everywhere found my brokers' folder and got back to the phone and 'made the call' to London/Alpari...

That same day [after about 10hrs brownout] I order UPS [next day free delivery;] and then realize it not gonna wake me up so then got idea about alarm.

.

Please excuse my ramble, but is for sure a frightening experience (am not wealth... yet!) and maybe my drone will get others to consider making 'contingency' plans... NOW :o)

Interesting ramble. Power failures very rare here,usually just a flicker until local utility relays flip and re-diredt power, generally serious enough to shutt down the pc. That plus Microslop shuting me down to instal some "supposedly" critical update have encouraged me to always have a hard stop in place.

I hope that I'm correct in assuming that once an order is opened; that order resides on the brokers server and the stop will be activated regardless of whether or not the ea is working. Of course trailing stops won't work but that is more a matter of lost opportunmity than lost cash.

Bigger fear is "Trade Context Busy", that too has only happened once, while trying to manually capture quick profits on a sudden spike, even after spike couldn't close again I'm not too sure what the consequences are for orders resident on the broker's server.

the learning continues.

Keith