BUG IN CURRENT MT4 : PRICE AND MARKETINFO PRICE ARE INCORRECT

 
Not going to argue about this. It's a bug. It's been confirmed by others. I'm done with this. MT4 is problematic, and I don't see it changing any time soon. So i'm deleting the original message.
 
Jack Thomas: The code above is very simple and shows a BUG in the prices being returned.
  1. Do you really think that no one has seen that before? You are in OnTimer before the first tick.
  2. Don't try to use any price or server related functions in OnInit (or on load,) as there may be no connection/chart yet:
    1. Terminal starts.
    2. Indicators/EAs are loaded. Static and globally declared variables are initialized. (Do not depend on a specific order.)
    3. OnInit is called.
    4. For indicators OnCalculate is called with any existing history.
    5. Human may have to enter password, connection to server begins.
    6. New history is received, OnCalculate called again.
    7. New tick is received, OnCalculate/OnTick is called. Now TickValue, TimeCurrent, account information and prices are valid.

 
whroeder1:
  1. Do you really think that no one has seen that before? You are in OnTimer before the first tick.
  2. Don't try to use any price or server related functions in OnInit (or on load,) as there may be no connection/chart yet:
    1. Terminal starts.
    2. Indicators/EAs are loaded. Static and globally declared variables are initialized. (Do not depend on a specific order.)
    3. OnInit is called.
    4. For indicators OnCalculate is called with any existing history.
    5. Human may have to enter password, connection to server begins.
    6. New history is received, OnCalculate called again.
    7. New tick is received, OnCalculate/OnTick is called. Now TickValue, TimeCurrent, account information and prices are valid.

1: Irrelevant that it has been encountered before. It happens when I put the code in OnTick() as well. You're wrong. Don't assume things.

2: referencing the information within OnTick itself produced the SAME results. It's NOT my code.

  1. Yes terminal starts.
  2. Code is loaded, and variables are processed, etc etc etc. I do NOT depend on a specific order. I only depend that the information is correct when I reference it.
  3. OnInit() is not the problem.
  4. I'm not dealing with an indicator. This is irrelevant at this point.
  5. No password is needed to get the ASK or MODE_ASK. The data is available in the terminal memory.
  6. Again. Not relevant. There IS NO OnCalculate() in an EA. It is always handled via OnTick() and OnTimer() for an EA.
  7. When a tick is received is is processed THAT IS NOT THE PROBLEM. The problem is MT4 current build as indicated, HAS A BUG. PAY ATTENTION. It is NOT my code.

It does NOT matter if my code is in the OnTick() or OnTimer(). Please pay attention.

Regardless of where the code is at, MT4 DOES NOT return the correct data.  THIS IS A CONFIRMED BUG BY SEVERAL OTHERS.

Again, it's pointless to even discuss this. MT4 is obsolete product and there are no plans to fix it.




 

BUT.... When the new bar is created, MT4 references the OLD data and does not update the bar creation data.

It's a confirmed bug.

For example, THIS code was executed OnTick() no timer involved.


PROOF... IT'S A BUG. NOT MY CODE.

 

It's an offline chart, running a incompatible timeframe, and running unknown code.

What would you expect have you tried 

RefreshRates();

You claim it's not even your code, but you are so sure about the problem not being in the code.

How do you know, really.

There are many limitation to the platform which is why we are migrating to version 5.

Have you found same bug on that one as well?

It's a waste of time to discuss the old one.
 
Marco vd Heijden:

It's an offline chart, running a incompatible timeframe, and running unknown code.

What would you expect have you tried 

You claim it's not even your code, but you are so sure about the problem not being in the code.

How do you know, really.

There are many limitation to the platform which is why we are migrating to version 5.

Have you found same bug on that one as well?

It's a waste of time to discuss the old one.

Marco,

Yes, I also tried the refresh rates. Thank you for the suggestion.

It works "most" of the time, but the problem is that it still on occasion returns invalid data, and when it does that, it doesn't matter if the rates are refreshed. it's like it's "stuck" there and unable to clear the value.

It's very strange.

It doesn't matter that it's an offline chart. A candlestick still has the same information on it, Open, Close, High, Low, Time, etc...
Offline or Online is irrelevant in regard to the data assigned to the specific candle being referenced.

It's an issue that MT4 doesn't return the correct data, and that THOUSANDS of users still run MT4 because their brokers do not support MT5.

I never claimed the code wasn't mine. I said the PROBLEM was not my code.

It isn't a waste of time to discuss it, if it is impacting clients.

If Metaquotes is going to continue to distribute MT4 to brokers, then it's an issue that needs to be resolved by Metaquotes.

If there isn't intention of fixing it, and it is truly the intent to stop distributing it, then Metaquotes should STOP providing MT4 terminals to brokers to distribute.

Also, it isn't possible to just switch my clients over to MT5 since they are US Based traders. Their brokers do not provide MT5 as a platform.

 
Hi gents, what bug do you discuss here?
 
Jack Thomas:
Not going to argue about this. It's a bug. It's been confirmed by others. I'm done with this. MT4 is problematic, and I don't see it changing any time soon. So i'm deleting the original message.

Why doing that ?

Again, it's pointless to even discuss this. MT4 is obsolete product and there are no plans to fix it.

That's not true, there is a beta undergoing. I had 2 tickets fixed, available in next release.

Nobody can confirm it's a bug now (I didn't see any information here that allows it), it will not be reported to Metaquotes and not fixed for sure.

 
Alain Verleyen:

Why doing that ?

That's not true, there is a beta undergoing. I had 2 tickets fixed, available in next release.

Yes it IS true.. We'll see what happens, but if MT4 were not being phased out, then it would still be available from the website.

It isn't available for public downloads any longer and according to metaquotes it isn't going to be made available to the public again.

Yes they might fix bugs that come up for now, but the plan is to phase it out and to focus only on MT5.

Or am I wrong?

 
Jack Thomas:

Yes it IS true.. We'll see what happens, but if MT4 were not being phased out, then it would still be available from the website.

It isn't available for public downloads any longer and according to metaquotes it isn't going to be made available to the public again.

Yes they might fix bugs that come up for now, but the plan is to phase it out and to focus only on MT5.

Or am I wrong?

The plan is to focus to MT5, right. But up to now, they continue to fix important bugs on MT4.

I don't understand why you removed the relevant information on this "bug", it is very selfish attitude while a forum is to share information and experience.

Reason: