Wishes for MQL5 - page 77

 
chv писал(а) >>

It won't show a line with a warning about an unused function - double click moves to the first line of the Expert Advisor, not to the beginning of this function.
Something like: Function "sdfsdgbgfgnh" is not referenced and will be removed from exp-file.

Well, that's right!

:)

You forgot to insert the function call into the Expert Advisor.

The compiler has warned you and did not insert this function into the executable file.

The author usually knows which functions he used in the Expert Advisor, where they should be called and where the text of these functions is.

Or maybe I'm wrong?

In short!

You can double-click on errors.

If you forgot to put a parenthesis, you will have to search manually!

If you forget to make a function call, you have to search for it manually!

What other errors won't double-click on?

 
string StringConcatenate(. ...)
Forms a string from the passed parameters and returns it. Parameters can be of any type. The number of parameters can not exceed 64.
I wish ps= StringConcatenate(g_Profit); would also work! Why should I limit it to less than 2 parameters?
 
vvavva писал(а) >>
string StringConcatenate(. ...)
Forms a string from the passed parameters and returns it. Parameters can be of any type. The number of parameters cannot exceed 64.
I wish ps= StringConcatenate(g_Profit); would also work! Why limit the number of parameters to less than 2?

Because this is string concatenation. ("strings" is plural).

In MQL5, a simple assignment ps=g_Profit will work, but the program will generate a warning about the implicit type conversion. To avoid the warning message, the explicit conversion can be performed

ps=(string)g_Profit;

 
stringo писал(а) >>

Because it is a concatenation of strings. ("strings" is plural).

In MQL5, a simple assignment ps=g_Profit will work, but with a warning about the implicit type conversion. To avoid the warning message, the explicit conversion can be performed

ps=(string)g_Profit;

I understand that for STRINGS! BUT if there is a 64 limit, it means there is a check, and if there is a check, why not skip one variable!?

it's not complicated!

in 4 we can ps=g_Profit; but in the process, variables may be added and it is better to use

string StringConcatenate( ...)
for now ps= StringConcatenate("",g_Profit);

it's not clear to me why there's a limit on one variable!?

 
vvavva писал(а) >>

I understand that for STRINGS! BUT if there is a 64 limit, it means there is a check, and if there is a check, why not just skip one variable!?

it's not hard!

you can use ps=g_Profit; but in the process, variables can be added and it's better to use

string StringConcatenate( ...)
for now ps= StringConcatenate("",g_Profit);

I don't understand why there must be one variable restriction!

So this is not a request to MQL5? Why do you write it here then?

 

these are wishes for all MQL numbers from 4 onwards! i wish there were less restrictions!

and that the limitations were written in the help!

if it is possible!

 
stringo писал(а) >>

To avoid a warning, an explicit conversion can be made

ps=(string)g_Profit;

It's beautiful.

 
stringo >> :

Because it is a concatenation of strings. ("strings" is plural).

In MQL5, a simple assignment ps=g_Profit will work, but with a warning about the implicit type conversion. To avoid the warning message, the explicit conversion can be performed

ps=(string)g_Profit;

In many languages you can explicitly convert through:


ps = g_Profit + "";

 

I will try to write not as a wish, but as something that is not currently possible to do in MT (hopefully the developers will see what and how to do it)

You need an indicator:

  1. Which reflects the sum of all "true" exchange rates of currency pairs in the terminal and containing, say, EUR.
  2. Under the "true" rate of a currency pair is understood(Ask-Bid)/2 + Bid
  3. The indicator should work equally correctly both on history, and at the current moment in time, i.e. for any change of Ask and/or Bid of any currency pair it will be reflected in the indicator.
  4. The indicator's work should not change on the history and in the real time mode, ie if I attaching it to the real account and write all of its data into a file, then I will get the same results, running it in the tester for the same period.

If MQL5 allows you to create such indicators, it will be a good help in creating (and studying) multicurrency TS systems.

 

one more request (to all MQLs)!

When you change the account, when the Expert Advisor works in a loop and the EA button is pressed, the accounts do not match!

Suppose the Expert Advisor finishes its work first, and then it changes the account, but now the start (cycle) is still running and the account has already changed

and i have to do extra checks!

Reason: