MetaTrader 4 Build 574 with Updated MQL4 Language and Market of Applications Released - page 8

 
angevoyageur:
The files in Include directories are the Standard Library provided with MT4. They contain classes that shouldn't be changed as they are updated with MT4 new build. See documentation of mql5.


I see, so they should be treated as a standard.

I think I still have to avoid them if possible, they have some unsafe features, like many objects inherit from CObject, but do not implement its Compare() method.

 
Ovo:


I see, so they should be treated as a standard.

I think I still have to avoid them if possible, they have some unsafe features, like many objects inherit from CObject, but do not implement its Compare() method.

Compared() method is virtual, why do you think it's unsafe if not implemented on an inherited class ?
 
angevoyageur:
Compared() method is virtual, why do you think it's unsafe if not implemented on an inherited class ?

Because the implementation in CObject always returns equal.

Common pattern for implementation of compare() should look like this:

 
Ovo:

Because the implementation in CObject always returns equal.

Common pattern for implementation of compare() should look like this:

Yes you are right, but it's not a big deal, if you are using the classes hierarchy, you probably know which one are comparable or not.

Anyway thank you for your explanation.

 

Hi,

Great enhanced features for MT4, but the main lake for me is the Debugger which is UNUSABLE. I can't debug an EA or Indicator during backtest (Visual or not), I do not want to wait for a tick in real market to have my breakpoint reached.

This feature will be awesome if it can be used during backtest, I do not understand the utility of this in real time market. More over, how can I debug during weekend, impossible !!!


Please Metaquotes, could you provide a real debugging feature and let us the ability to debug during backtest.


Thanks

 
yousky:

Hi,

Great enhanced features for MT4, but the main lake for me is the Debugger which is UNUSABLE. I can't debug an EA or Indicator during backtest (Visual or not), I do not want to wait for a tick in real market to have my breakpoint reached.

This feature will be awesome if it can be used during backtest, I do not understand the utility of this in real time market. More over, how can I debug during weekend, impossible !!!


Please Metaquotes, could you provide a real debugging feature and let us the ability to debug during backtest.


Thanks

Well, though you cannot trade when the market is closed, you still can generate ticks to fire the OnTick event, same way as for the old 509. Script attached.
Files:
ticktick.mq4  1 kb
 

Wouldn't it be a great idea if the mt4 client would get just these two time-information from the mt4-server where it is logged in?:

1) GMT-TimeShift of the server and

2) what DST-TimeShift is practised? (Euro-TimeShift, USA-TimeShift, ...)

It needs only 2 additional functions (and the server-sided numbers of course!)

AccountTimeshift(); // in seconds to be used without further calc.: GMT = iTime(..) + AccountTimeshift();

AccountDST(); // 0=no DST, 1=Euro, 2=USA, ... // need to know for backtests

This would make many things a lot easier!!

gooly

 
gooly:

Wouldn't it be a great idea if the mt4 client would get just these two time-information from the mt4-server where it is logged in?:

1) GMT-TimeShift of the server and

2) what DST-TimeShift is practised? (Euro-TimeShift, USA-TimeShift, ...)

It needs only 2 additional functions (and the server-sided numbers of course!)

AccountTimeshift(); // in seconds to be used without further calc.: GMT = iTime(..) + AccountTimeshift();

AccountDST(); // 0=no DST, 1=Euro, 2=USA, ... // need to know for backtests

This would make many things a lot easier!!

gooly

Have you looked at the new Date/Time functions ?
 
angevoyageur:
Have you looked at the new Date/Time functions ?


No, but now I did - wonderful!!
 

https://www.forex-tsd.com/metatrader-4/32924-metatrader-known-bugs-11.html#post657595

When IndicatorCounted() is called from offline charts, it always return 0 as a result.

It is happening regardless of the way how ticks are simulated and is causing indicators to recalculate all the bars all the time.

It is happening in the new metatrader 4 as well as in metatrader 4 build 509.
Reason: