Step back - page 6

 
Contender:

Isn't that the objective?

On every bar, reread the subject...
 
IvanIvanov:
On every bar, re-read the thread...
It turns out the problem has been spelt out to you in the first reply.
 
Contender:
In order to go back, you have to remember the state you want to go back to.

What do you need to remember? Can you be more specific? OHLC to remember? Or do you need to remember the indicator values? Don't you want to recalculate it? Note, nobody is proving to you that it's easy to do. And no one is suggesting a solution. You are trying to prove that it is impossible, without knowing how everything works.

What are we arguing about anyway? That's never going to happen in MT. MQ is not interested in this and therefore I'll stop discussing it.

 
IvanIvanov:

So how is it implemented in others?


I thought you were going to tell us.
 
AlexeyVik:

What do you need to remember? Can you be more specific? OHLC to remember? Or do you need to remember the indicator values? Don't you want to recalculate it? Note, nobody is proving to you that it's easy to do. And no one is suggesting a solution. You are trying to prove that it is impossible, without knowing how it all works.

What are we arguing about anyway? This will never happen in MT. MQ is not interested in this and therefore I am stopping this discussion.

Read the second post on the first page, it describes what you need to remember.

 
Contender:

Isn't that the objective?

It is not (I don't even understand why we need to remember everything that happened to the tick accuracy and with values of all variables). It is enough to rewind the chart one bar backward (as it works in the online MT - step by step) and give a command to indicators to recalculate the values (IndicatorCounted() = 0, prev_calculated = 0). Trades renew/cancel according to the account history, from them recalculate balance, funds and margin. The solution of such a task does not require any fabulous resources.
 
Scriptong:
Not like this. Just rewind the chart back one bar (as it works in online MT) and command the indicators to fully recalculate the values (IndicatorCounted() = 0, prev_calculated = 0). The trades renew/cancel according to the account history. The solution of this problem does not require any fabulous resources.
And what if the indicator/advisor works with some global variables? What if it works with graphical objects? What if it works with files?
 
Contender:
I thought you were going to tell us.
I thought you were the programmer... not me....
 
Contender:
What if the indicator/advisor works with some global variables? What if it works with graphical objects? What if it works with files?
I wrote above - give a command to completely recalculate the indicator values. How do normally written indicators work in such cases? They start all over again: delete objects, overwrite files.
 
Scriptong:
I wrote above - give a command to completely recalculate the indicator values. How do normally written indicators work in such cases? They start all over again: delete objects, overwrite files.

That is, not a recalculation, but a restart followed by a recalculation. For an open price indicator, it might be fine, but that's not certain.

Reason: