However, when the EA is on the chart and if MT4 is restarted, if I were to click on the EA properties and click "OK" then the EA gets initialized and I don't get a divide by zero message when an entry signal is generated.
Is there code that can be inserted into the EA so that it forces it to initialize after an MT4 restart?
Do you get any error messages when you switch your code to strict?
Hi nbtrading, didn't code it to strict. It was a simple fix. Got it working, for now.
This time my code did not compile with the Metaeditor 1026 update, again.
So far the enumerations got casted to the int type implicitly. But it is no longer true, now they generate
"ambiguous call to overloaded function"compile error if there are more overloaded functions (e.g. one with int parameter, the other with long parameter).
As usual new errors surfacing : they still did not solve the issues when the code is first started. Not after a whole 1.5 year
Well, they claim they fixed something in the new release. I have no energy left for re-testing it with every new release, when there is a new release every week.
But I do not understand the reason for removing the implicit cast of enumerations to int, which requires fixes everywhere in all my code after a year.
I just realized it was not only enumerations. I am getting the "ambiguous call" error for other types, too.
Rolling back this build.
Same old story - seems like they will never learn
Build 765 : ChartGetInteger(0, CHART_HEIGHT_IN_PIXELS,...) returns wrong values
Problems with some resources types when used in indicators and then called from an EA
I checked the related post in the Russian part, and it looked like adding the indicator as a resource to an EA did work (somehow)...
When I checked this feature some time ago, it did not even compile.
For some reason when using metatrader in portable mode it downloads much less history data from the server (in regular mode it download to 2009, in portable only to 2012)