This forum is in read-only mode now. You may discuss your questions on forums of MQL4.community and MQL5.community

Bug Report List - build 143


Back to topics list
avatar
153
CoenWillemse 2004.12.22 03:32 
Congrats MetaQuotes - no more problems with the platform crashing when loading external modules!

However, I've had a few other problems with my code. MetaEditor allows the following to be compiled, which crashes MetaTrader:

int start() {
int buySell;

double indResults[2];
indResults[0] = -1;

buySell += indResults[0];
return(0);
}

Note that variable 'buySell' is an 'int' and array 'indResults[]' is a 'double'..... If I change variable 'buySell' to be a double, no further problems occur. Also, if I set 'indResults[0]' to '1', instead of '-1', no problems occur either...
avatar
153
CoenWillemse 2004.12.22 03:47 
Also, another small thing. If an Expert is started and a large string is entered as an input parameter, the string parameter being entered is left justified which is fine - i.e. the whole string is in view.

However, once the Expert is running and "F7" is pressed (to get the input parameters screen) and an attempt is made to modify the string parameter, the first half of the parameter contents is lost from view (if the parameter is a long string) - it looks like it's being right justified.

It's not a big problem - simply pressing the 'home' key brings the string back into full view. However, it's a bit cumbersome......
avatar
153
CoenWillemse 2004.12.22 04:01 
And.... another small bug. If a sell order is placed, The "Experts" log records the line:

"#<order number> sell placed ok"

which is fine. However, if the sell order is closed, the "Experts" log records the line:

"#<order number> buy closed ok".


There seems to be no problems with buy orders.....
avatar
153
CoenWillemse 2004.12.22 05:14 
Here's another bit of code that compiles alright but will crash MetaTrader...


int start() {

string periodDetails = getPeriodDetails();
Print(periodDetails);
return(0);
}

// Return period details as a String
string getPeriodDetails() {

string period;
switch (Period()) {
case 1: period = "M1"; break;
case 5: period = "M5"; break;
case 15: period = "M15"; break;
case 30: period = "M30"; break;
case 60: period = "H1"; break;
case 240: period = "H4"; break;
case 1440: period = "D1"; break;
case 10080: period = "W1"; break;
case 43200: period = "MN"; break;
default: period = "PeriodUnknown"; break;
}
}


Yep, the compiler doesn't spot the missing return - if the return is inserted, it works fine.
avatar
4464
Slawa 2004.12.22 11:15 
thanxx
avatar
153
CoenWillemse 2004.12.23 00:28 
And now for the weirdest bug of all - when opening an order, it's possible to use lot sizes of 2.1, 2.2, 2.4, 2.5, 2.6 etc but not 2.3! Lot sizes of 3.3, 4.3, 5.3 etc work without a problem. For whatever reason, a lotsize of 2.3 is an 'invalid lotsize'
avatar
153
CoenWillemse 2004.12.23 00:38 
And addition to the 'wierd bug' described above - a lotsize of 5.1 also comes up with the same error.
avatar
153
CoenWillemse 2004.12.23 11:54 
And yet another addition to the 'wierd bug' described above - a lotsize of 4.6 also comes up with the same error. So, up until now, it's been lot sizes of 2.3, 4.6 and 5.1 that come up with the "invalid lotsize" error. Somebody miss a few 'case' statements in a 'switch' statement by any chance?
avatar
4464
Slawa 2004.12.23 11:58 
Alexandr has reproduced this bug. we'll think
avatar
27
darkstonexa 2004.12.23 13:16 

There is an issue I noticed over the last couple of versions.

when attaching CCI indicator the level that should be -100 is always coming up as
429396.7296.

I know indicators will always remeber the last value you set..
but in this case it doesn't matter how many times I change it, everytime I go to add the same indicator again I keep getting
429396.7296 instead of -100 as one fo the level lines..

Back to topics list  
Download MetaTrader 5 (450 Kb, web installer) — a new terminal for financial markets