You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Hello Mohamed,
Instead of:
Wouldn't it be enough ?:
Regards,
Juan Luis
Hello Mohamed,
Instead of:
Wouldn't it be enough ?:
Regards,
Juan Luis
Hello Juan,
You are correct, it can be like what you mentioned also.
Regards,
Excellent article! However I did spot an error in one of the, and I also spotted an opportunity for a tip. The error is with the CopyBuffers,and using the same buffer index for the same handle. An indicator handle in MQL5 can only access a specific buffer using its corresponding unique buffer index in a call to the CopyBuffer() function.
So when you put:
It should be:
I guessing this was a typo but thought I should point it out just in case anyone else gets confused. It was correct in the full code, just not in the example.
Now for the litte tip...
Not a big deal but would definitely save you some unnecessary key strokes, when you wrote:
There's some extra quotation marks you don't need. To simplify, you could do this:
Other than that, I found the article very informative and detailed.
The only other thing I would add here is error handling in OnInit() and DeOnit(), and change the variable name from ADXDef to h_ADXDef (or handle_ADXDef), so it's more clear when reading the code and just makes it a better identifier which shows its specific purpose.
In OnInit():
And, in DeOninit():