Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 1381
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
There's nothing supernatural about it. The usual OBJ_BITMAP_LABEL and into it whatever you want as a resource. Kanvas works in OBJ_BITMAP_LABEL, too.
But your version is much easier for a novice developer.
Please learn how to insert code into a message.
And for the question: Read the documentation on CopyTicksRange
It doesn't work. Every time OnTick is called, the result of the variable Ticks is 0.
Are you sure you need past ticks on entry. 10 seconds is not that long, you can wait and count the actual ticks and their number.
In general, you need 2 variables for the first second and remember how many ticks there were in 9 seconds and sum them up, then count ticks for the next second, subtract the first and add the last one. The results should be stored either in an array or in a variable.
Are you sure you need past ticks on entry. 10 seconds is not that long, you can wait and count the actual ticks and their number.
In general, you need 2 variables for the first second and remember how many ticks there were in 9 seconds and sum them up, then count ticks for the next second, subtract the first and add the last one. These results are saved either in an array or in a variable.
So, this cannot be done through the CopyTicks and CopyTicksRange functions?
Thank you.
Doesn't work. Each time OnTick is called, the result of the Ticks variable is 0.
Read the documentation!!!
Or do you want all the documentation copied here piece by piece???
from_msc
[in] Date from which ticks are requested. Specified in milliseconds from 01.01.1970. If thefrom_msc parameter is not specified, then the ticks are returned from the beginning of the history. Ticks with time >= from_msc are returned.
to_msc
[in] Date, on which the ticks are requested. Specified in milliseconds from 01.01.1970. Ticks with time <= to_msc are returned. If parameterto_msc is not specified, all ticks until the end of the history are given .
Are you sure you need past ticks on entry. 10 seconds is not that long, you can wait and count the actual ticks and their number.
In general, you need 2 variables for the first second and remember how many ticks there were in 9 seconds and sum them up, then count ticks for the next second, subtract the first and add the last one. Save the results either to an array or a variable.
Why give such advice?
So it can't be done through the CopyTicks and CopyTicksRange functions?
Thank you.
Yes, you can. Read documentation, and then ask what you do not understand in the documentation. This way you will get to the truth quicker).
Why give such advice?
I do it myself. Why get into structures when you can fix short actions yourself.
I do it myself. Why get into structures when you can fix short actions yourself.
And I scratch my left ear with my right little finger... I can teach you... Do you need it? Don't teach others what you're doing through.....................
You can. Read the documentation and then ask what you don't understand in the documentation. That's the quicker way to the truth).
So... Read the documentation (again).
Question. What's wrong? It does not count neither with CopyTicksRange nor with CopyTicks