Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Nowhere without you - 6. - page 906

 
I have an old computer, it is eight years old. and in all this time only the hard drive and the video card have been changed. as if there were no complaints about the rest - the workhorse coped with its needs. until it is now stumped in the RAM ... your answer I understand that you can safely put in 2 more gigabytes of RAM and the idea is that you can continue to use
 
Who knows about the new objects, please tell me which object now serves as a software object, at least only for filling with a given colour with a binding to the upper right corner? I can not find, namely, fill colour, not a frame, and the whole figure, and that with a binding, namely to theupper right corner! Maybe something from old 4 works, because its documentation was thrown out, and this new one is full of restrictions, and possibilities... Thanks!
 

Hello: Could you tell me how to do this: there is a custom function that has a number of parameters set by default. If the first of the set parameters needs to be left unchanged and the following parameters need to be changed, is it possible to do without rewriting this parameter?

// Есть функция
int fNumBar(datetime TimeBar,int TF, string Text="Бар не найден! Работа завершена.",bool Flag=True,int QBarsForAnalisys=0);

// При обращении к ней параметр Text нужно оставить без изменений, Flag = False,QBarsForAnalisys=150.
Как ее вызвать? 
 
borilunad:
Who knows about the new objects, please tell me which object now serves as a software object, at least only for filling with a given colour with a binding to the upper right corner? I can not find, namely, fill colour, not a frame, and the whole figure, and that with a binding, namely to theupper right corner! Maybe something from old 4 works, because its documentation was thrown out, and this new one is full of restrictions, and possibilities... Thanks!
Well, if I understood the task correctly, it's quite possible to implementOBJ_RECTANGLE_LABEL https://docs.mql4.com/ru/constants/objectconstants/enum_object/obj_rectangle_label
 
delfik71091:

Hello: Could you tell me how to do this: there is a custom function that has a number of parameters set by default. If the first of the set parameters needs to be left unchanged, and the following parameters need to be changed, can you do without rewriting this parameter?

Well, call it like all the others, you give it what it needs

function call with needed parameters:fNumBar(TimeBar,60,"Bar not found! Job complete.", false, 150);

int fNumBar(datetime TimeBar,int TF, string Text="Bar not found! Work complete.",bool Flag=True,int QBarsForAnalisys=0);

{

here is the function body;

return(return anything or 0);

}

 
MVS:

So call it like everyone else, you give it what it needs.

function call with the right parameters:fNumBar(TimeBar,60,"Bar not found! Work complete.", false, 150);

int fNumBar(datetime TimeBar,int TF, string Text="Bar not found! Work complete.",bool Flag=True,int QBarsForAnalisys=0);

{

here is the body of the function;

return(return anything or 0);

}

But is it possible, without rewriting this line, to show the function that the default value should be used. I mean, the compiler understands that if parameters are omitted all the way through, then the default value should be used. In that case, is there some magic word to indicate that the default value should be used?
 
delfik71091:
But is it possible to show the function that the default value should be used without rewriting this string? The compiler understands that if parameters are omitted all the way through, the default value must be used. In that case, is there some magic word to indicate that the default value should be used?

How do you figure? Enter the defaults right away if the variable is inside, if they are at the end, then just don't write them:

int fNumBar(datetime TimeBar,int TF, string Text="Bar not found! Job complete.",bool Flag=True,int QBarsForAnalisys=0);

fNumBar(timebar, timeframe, text); // just don't write further bool Flag=True,int QBarsForAnalisys=0

If the required variable is at the beginning or inside by default, you must specify it, if it is at the end, you can omit it and it will take what you specify.

Also, if you don't use it at all, or it is always constant, then move it to the function body, and thus reduce the design call.

Describe in more detail what you are doing, maybe there is another solution.

 

Good afternoon !

Please suggest functions in mql4 to return amounts of money from investment requests as well as amounts on withdrawal requests from investors for a PAMM account.

 
MVS:
Well, if I understood the task correctly, it's quite an implementation of OBJ_RECTANGLE_LABEL https://docs.mql4.com/ru/constants/objectconstants/enum_object/obj_rectangle_label

Thanks for the response! But it just doesn't simplify it, it complicates it exorbitantly with unnecessary checks, as if I'm sending something to the server, which is why I asked for help! Did it myself yesterday without enums and other wisdom! Works fine, and less than 40 lines of calling code with conditions and along with rectangle and text functions!

Just got stumped at first from the "Yuck" method, then applied my favourite "Yuck" method, and it worked! ;))

 
Good day!!! Guys, help me fix the indicator. When old builds worked fine, but I recompiled it with a new compiler and got a stack overflow error. How to fix it I'm not sure what to do now. I can't increase the stack in indicators :-(. I sure hope it will help. Thank you
Files:
Reason: