Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

con2mtapi fails when candle data not yet loaded and available #4

Open
eabase opened this issue Nov 14, 2020 · 1 comment
Open

con2mtapi fails when candle data not yet loaded and available #4

eabase opened this issue Nov 14, 2020 · 1 comment
Labels
bug Something isn't working

Comments

@eabase
Copy link
Owner

eabase commented Nov 14, 2020

When running the script for the first time on a certain symbol and timeframe, the
candle data will not be available in the MT4 terminal buffer, so the script will fail.

The solution is to just run it again and MT4 will most likely have already downloaded the new data.
However, I have not been able to resolve this issue.

@eabase eabase added the bug Something isn't working label Nov 14, 2020
@eabase
Copy link
Owner Author

eabase commented Dec 3, 2020

Just for reference:

From here:

If data (symbol name and/or timeframe differ from the current ones) are requested from another chart, the situation is possible that the corresponding chart was not opened in the client terminal and the necessary data must be requested from the server. In this case, error ERR_HISTORY_WILL_UPDATED (4066 - the requested history data are under updating) will be placed in the last_error variable, and one will has to re-request

So:

ArrayCopyRates will return an error if there is no history at all (ERR_NO_HISTORY_DATA = 4073.) Repeated calls also fail until the download is complete. When there is history but not up to date, ArrayCopyRates returns valid AND also sets _LastError to ERR_HISTORY_WILL_UPDATED (= 4066.)

Repository owner deleted a comment from HMR25 Mar 2, 2024
Repository owner deleted a comment from s-ikeda141104 Mar 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant