Metatrader known bugs ... - page 7

To add comments, please log in or register
Bob Fisher
316
Bob Fisher  
MrPip:
Do you get the same results when the macd values are placed in local doubles?

You might also try multiplying slope by 10000 to move the decimal place before outputing the label.

Otherwise roundoff will show 0 for very small values of slope.

I worked on an EMA angle indicator years ago and that was the problem.

The angles were always very small. Even multiplying by 10000 showed angles often less than 1.

Robert

Hi Robert,

Just re-read this and found you missed my point.

Dim somearray[10];

Print(DoubleToString(somearray,2)); // prints as 0.00

The bug is the interpreter is not recognizing somearray as an array and flagging it as an illegal construct.

Bob Fisher
316
Bob Fisher  

OrderType( ) and other associated order parameters.

The documentation states clearly that the Orderxx functions must be selected by and OrderSelect() call.

Note: order must be selected by OrderSelect() function.

I had erroneously assumed that and OrderSend() or OrderModify() would automatically Select the order and its associated parameters. This is NOT the case.

Valid information is contained in the parameters only if the order has been selected.

The real bug is that if you are running multiple charts, say EURUSD & GBPUSD, the information contained in EA controlling the EURUSD pair can contain Order parameter data from the other PAIR!

This is a horrendous bug as it indicates that Multiple Concurrent EAs are not totally separated in their own memory workspace and you cannot determine the OrderOpenPrice unless you process all open orders and select the appropriate order and immediately set internal variables to use. Even then you cannot guarantee that the information received may not be corrupted since the possibility exists that one or more of your other EAs may be performing the same operation at the same time. This is not as remote a chance as it may seem since several pairs are related by either their base or counter currency. It appears to me that there is only one set of Orderxx() values for each Terminal session and this set is used by all EAs.

Below is a file dump of an EA controlling GBPJPY with the OrderOpenPrice & OrderStopLoss just after the OrderOpen call that created 25505862. As you can see, the values,1556.87, are from an EA running XAUUSD. Interestingly, the Terminal Display of all orders shows #25505862 with values appropriate to GBPJPY.

OrderPlaced 7:00:05 -1 0 25505862 4 1556.87 1549.7 1549.7 0 D:X1

CalculateStopLoss 146.709 0 145.943 2 0.01 0.01 0.2 0

MrPip
546
MrPip  
Tzuman:
Hi Robert,

Just re-read this and found you missed my point.

Dim somearray[10];

Print(DoubleToString(somearray,2)); // prints as 0.00

The bug is the interpreter is not recognizing somearray as an array and flagging it as an illegal construct.

DoubleToString allows array elements but not an entire array. You would need to use an index to the array like Print (DoubleToStr(somearray, 2));

Robert

techmac
2973
techmac  

Something I noticed with build 482 : when I have multiple demo accounts, sometimes, for some reason (I could not find when and why) metatrader deletes all but the active account. Not that it writes out that they are invalid or anything similar : those accounts disappear from the list of accounts for good

techmac
2973
techmac  

One more issue with build 482 : I can not download data in history center any more. It does not matter how much data I have(I have tried even deleting the 1 minute data) it always says : "There is no new data for symbol nnn" and does not download the data as it used before. Does anybody have that same issue?

Mladen Rakic
135725
Mladen Rakic  
techmac:
One more issue with build 482 : I can not download data in history center any more. It does not matter how much data I have(I have tried even deleting the 1 minute data) it always says : "There is no new data for symbol nnn" and does not download the data as it used before. Does anybody have that same issue?

Tested it on my terminal (build 482 too) and it seems that I have that kind of a problem too. Strange

techmac
2973
techmac  
mladen:
Tested it on my terminal (build 482 too) and it seems that I have that kind of a problem too. Strange

One more "present" from metaquotes

Mladen Rakic
135725
Mladen Rakic  

Waiting to see build 500 (since my broker still did not upgrade to build 500). It seems that there is some mix-up with data download now and that is rather unpleasant at the least for strategies back-testing

Mladen Rakic
135725
Mladen Rakic  

Bug considering arrays (it seems that it starts from build 482, but I am not sure)

When declaring a local array like this code :

int init() { return(0); }

int deinit() { return(0); }

int start()

{

double array[];

if (ArrayRange(array,0)!=50) ArrayResize(array,50);

return(0);

}

On a new tick array is not reset, and the size on second tick is 50 not 0 as it should be. It is a clear error since the array is declared as local to the routine/function (it is not declared as static nor is it declared on a global level) and should be zero sized on each an every new tick. Same happens in indicators as well as in EAs. That might one of the possible reason why are there so much complaints that some code that worked before does not work starting from build 482. The only solution for now is to zero size (if necesary and in a lot of cases of dynamically using arrays it is a must) using ArrayResize(array,0).

So, if using arrays in your code, be careful since it seems that they are having a buggy builds (again, since they had similar problems with arrays a few years ago) that do not work with arrays as they should

techmac
2973
techmac  

My broker still keeps build 482. Now it already makes me wonder why (but seeing the stuff the build 500 does, I do not wonder so much, since among other things, they report that some perfectly legal code from mql code base can not be compiled any more - one nonsense following the other)

To add comments, please log in or register