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

Simon Gniadkowski
17348
Simon Gniadkowski  
Ovo:

Does using OnStart() in place of start() solve the issue? If yes, I would not dig into it. They combined two scripts into one and it is a miracle that the mess somehow works. This is not a real issue, just annoying.
I want to keep using as much of my existing code as possible, that is what we were told would be possible . . . I'm not going to do that just to be pig headed but it's what should still work. Part of what we are doing here is testing and reporting back issues so for now I'll regard this is an issue to be fixed.
Ubzen
5301
Ubzen  
RaptorUK: I want to keep using as much of my existing code as possible, that is what we were told would be possible . . . I'm not going to do that just to be pig headed but it's what should still work. Part of what we are doing here is testing and reporting back issues so for now I'll regard this is an issue to be fixed.

Is it too late to say we're being fed mql5 in small bits and pieces?

People who used . dot notations within their codes need to edit them.

So if Meta-Quotes document what we're already Un.covering would that make you OK with it?

Just asking...

Ex Ovo Omnia
3049
Ex Ovo Omnia  
RaptorUK:
I want to keep using as much of my existing code as possible, that is what we were told would be possible . . . I'm not going to do that just to be pig headed but it's what should still work. Part of what we are doing here is testing and reporting back issues so for now I'll regard this is an issue to be fixed.

I see. But I am not a tester, I am just a user trying to find a way it works. As far as there is any workaround available, I do not care much.
Ian Venner
2397
Ian Venner  
RaptorUK:
All my scripts have init() and deint() and there have never been issues on 509 or earlier. I don't use templates . . .

Yes you do lol they are the comment headers of the standard MQ EA template: Expert.mqt

//+------------------------------------------------------------------+
//| expert initialization function                                   |
//+------------------------------------------------------------------+

//+------------------------------------------------------------------+
//| expert deinitialization function                                 |
//+------------------------------------------------------------------+

//+------------------------------------------------------------------+
//| expert start function                                            |
//+------------------------------------------------------------------+
I think 509 probably just ignores the init() and deinit() when run from the scripts folder. 582 seems to be more strict about everything, it probably sees those functions as illegal in a script
Simon Gniadkowski
17348
Simon Gniadkowski  
ubzen:

Is it too late to say we're being fed mql5 in small bits and pieces?

People who used . dot notations within their codes need to edit them.

So if Meta-Quotes document what we're already Un.covering would that make you OK with it?

Just asking...

I know we are being moved towards mql5 . . . for me that is as obvious as something that's really obvious . . .

I used periods in some of my variable names for a particular Indicator, that change was documented, I replaced my periods with underscores, my code compiled and worked.


It doesn't really matter if I'm OK or not OK with it, it is what it is . . . I'd be happier if they laid out the scope of the changes up front so we all knew what we were facing instead of treating us like mushrooms . . . do you remember this ? https://forum.mql4.com/57476
The differences are not critical and can be easily corrected in the code.

Simon Gniadkowski
17348
Simon Gniadkowski  
SDC:

Yes you do lol they are the comment headers of the standard MQ EA template: Expert.mqt

I think 509 probably just ignores the init() and deinit() when run from the scripts folder. 582 seems to be more strict about everything, it probably sees those functions as illegal in a script

No I don't use templates . . . 509 executes the init() and deint() in a Script . . .

2014.01.31 17:27:27 TestWindowScreenShot SP500,H1: removed

2014.01.31 17:27:27 TestWindowScreenShot SP500,H1: uninit reason 0

2014.01.31 17:27:27 TestWindowScreenShot SP500,H1: deinitialized

2014.01.31 17:27:27 TestWindowScreenShot SP500,H1: TestWindowScreenShot.mq4 script, this is in deinit() . . .

2014.01.31 17:27:27 TestWindowScreenShot SP500,H1: ChartGrab - Path: shots\ Filename: SP5002014-1-17.gif

2014.01.31 17:27:27 TestWindowScreenShot SP500,H1: initialized

2014.01.31 17:27:27 TestWindowScreenShot SP500,H1: TestWindowScreenShot.mq4 script, this is in init() . . .

2014.01.31 17:27:27 TestWindowScreenShot SP500,H1: loaded successfully

Simon Gniadkowski
17348
Simon Gniadkowski  
Ovo:
I see. But I am not a tester, I am just a user trying to find a way it works. As far as there is any workaround available, I do not care much.
Workarounds that you implement to cope with bugs can end up failing when the bug gets fixed . . . it's better to know if an issue is a bug or a misunderstanding before implementing a workaround. IMO.
Ian Venner
2397
Ian Venner  
RaptorUK:

No I don't use templates . . . 509 executes the init() and deint() in a Script . . .

You are right I tested it on both 509 and 582 they both execute those functions even though the script.mqt templates do not include them. There must be some other reason why 582 said yours was not a script.
Ian Venner
2397
Ian Venner  
RaptorUK:
Workarounds that you implement to cope with bugs can end up failing when the bug gets fixed . . . it's better to know if an issue is a bug or a misunderstanding before implementing a workaround. IMO.

I agree, anything you do that is not according to the documentation is unprotected from changes made by updates later on and is therefore unsafe.
Ex Ovo Omnia
3049
Ex Ovo Omnia  
RaptorUK:
Workarounds that you implement to cope with bugs can end up failing when the bug gets fixed . . . it's better to know if an issue is a bug or a misunderstanding before implementing a workaround. IMO.


Sure. But using the OnStart() is not a workaround, it is other syntax of the same though not identical function. I am afraid that without marking one of them obsolete, we may turn schizophrenic - one would prefer the new syntax, while others the recent one... I am trying to make a guess which one survives longer and use that one.

In case I use a workaround, I create a test case as well, so if change appears, I have a good chance to spot it. With OOP feature, the unit testing is much easier than before. But in the recent MQL they never fixed bugs I replaced by other solution.