Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 1082

 

It is understandable that if you delete the EA, it will start again. But on all 30 windows it runs with different parameters. It takes me half an hour or an hour to restore everything and rewrite all parameters for the EA in all windows

***

 
gifrom:
It is clear that if the EA is deleted, it will start again. But on all 30 windows it is running with different parameters. It takes me half an hour or an hour to restore everything and rewrite all parameters of the Expert Advisor in all windows

You need to make a change to the advisor like this:

if(OrderTotal() == 0) Lot=StartLot;

In the end, if there is nothing in the market, it will either not yet, or already, start with the starting lot.

P.S. And "magic" does not need to be touched here.
 
Vitaly Muzichenko:

You need to make a change to the advisor like this:

Bottom line, if there's nothing in the market, it's either not there yet, or it's already there, it will start with the starting lot.

P.S. And "magic" does not need to be touched here.

Thank you very much

***
 
pivalexander:


Thank you very much for your helpful advice on the subject! It's just the right thing to do.
I've already got tired of experimenting with CHART_EVENT_MOUSE_MOVE as the experts advised above. ;-|
 
Maksims Ignatovs:
Thank you very much for the helpful tip on this subject! Just what I needed.
I`ve already had enough of experimenting with CHART_EVENT_MOUSE_MOVE, as the experts advised above. ;-|

Is that a poke at me? And I told you to read the help and gave you all the links. Turns out I should have poked you with my spout?

What I wrote to you:

Pay attention to the line "In particular - left mouse button scrolling graph."

You can even follow the link and read where I directed you.

But "experimenting with CHART_EVENT_MOUSE_MOVE as advised above"
that was entirely your initiative because you were too lazy to go somewhere and read the example from the pro help:

CHART_MOUSE_SCROLL - chart scrolling with the left mouse button

 
This is a question but the function
iOpen()

to get the opening prices accesses an array embedded in MT4 or accesses the broker's data archive, I'm just wondering if it makes sense to write an array and collect these prices or use this function?

Can such an entry work?

typedef template <typename T>T(*Funk)(T,T);
 

I missed something. Can you tell me why prices on the chart and on the tick chart can be permanently different? and Bid and Ask. I've never noticed this before. I've checked prices on the flipper just in case - zeros. I checked on OnTick and got what is on the tick chart. I also check what's on the main chart and what's on the tick.

 

If I want to create a function that takes an array as input, what should I put in brackets ?

void ARREY ( ? ) 
{...}
 
Viatcheslav Pashkov:

If I want to create a function that takes an array as input, what should I put in brackets ?

void ARREY ( double &a[] ) 
 

Am I correct in assuming that the value of the optimised parameter is irrelevant by the optimisation if the Genetic Algorithm Optimisation checkbox is unchecked, due to a full enumeration of all optimised parameter values?


Reason: