Metatrader known bugs ... - page 36

 
mladen:
Not a bug bu a change in how metatrader works :

If you used 0 instead of NULL when calling indicators before they were working. Now they are not going to work. Use NULL (in example like this iRSI(0,0,RSIPeriod,RSIPrice,I) this will not work but this iRSI(NULL,0,RSIPeriod,RSIPrice,I) will work)

Bug is in the compiler : compiler does not issue any warning at all, neither does the terminal raise any run time error

It means that it is not enough to compile?

That even then it can refuse to work?

 
on my own:
It means that it is not enough to compile? That even then it can refuse to work?

Unfortunately but it is so with the new metatrader 4

You are never sure if it will work as it should

 

iCustom calls to missing indicator

This is not a "bug" it is more a lack of thought, but has long been there:

When an EA does an iCustom call and that indicator is not there, it should give a warning.

Instead you get strange results (based on an assumed value of '0' I believe).

I don't know if there is any single code that can make that check.

Big Be

 

See reason for edit.

 
Big Be:
This is not a "bug" it is more a lack of thought, but has long been there:

When an EA does an iCustom call and that indicator is not there, it should give a warning.

Instead you get strange results (based on an assumed value of '0' I believe).

I don't know if there is any single code that can make that check.

Big Be

Try something like this :

//------------------------------------------------------------

//

//------------------------------------------------------------

#property indicator_chart_window

#define ERR_INDICATOR_CANNOT_LOAD 4072 // Cannot load custom indicator

extern string indicatorName = "";

//------------------------------------------------------------

//

//------------------------------------------------------------

//

//

//

//

//

int init() { return(0); }

int deinit() { return(0); }

int start()

{

static bool tested = false;

static bool wrongIndicator = false;

if (!tested)

{

ResetLastError();

double dummy = iCustom(NULL,0,indicatorName,0,0);

tested = true;

wrongIndicator = (GetLastError()==ERR_INDICATOR_CANNOT_LOAD);

}

if (wrongIndicator) return(0);

//

//

// normal processing

//

//

return(0);

}
 

Thank you mladen,

I will play with that missing indicator code.

Big Be

 

While, just one example, backtester crashes 50% of time, they decided that at August the 1st build 509 is going to be discontinued. Of runtime crashes an nonsense that happens not worth talking - they will not correct it anyway

 
techmac:
While, just one example, backtester crashes 50% of time, they decided that at August the 1st build 509 is going to be discontinued. Of runtime crashes an nonsense that happens not worth talking - they will not correct it anyway

Unfortunately to say that's the way we have to accept it if we continued to use metatrader 4.

 
matfx:
Unfortunately to say that's the way we have to accept it if we continued to use metatrader 4.

Yep

Some "smart" guys have decided that worse is better for us (users)

 
techmac:
Yep Some "smart" guys have decided that worse is better for us (users)

They claim that it has 30 improvements (sic : 30). They are probably well hidden though