[WARNING CLOSED!] Any newbie question, so as not to clutter up the forum. Professionals, don't go by. Can't go anywhere without you. - page 775

 
Vinin:

If this happens again, I will be forced to request a ban.

Posting decompiled indicators is a violation of forum rules.

again different standards in ethics, morality and understanding of forum rules?

;)

 
FoxUA:

So I understood that the function call can be written simply

PrAskLim = StopLossLastPos(OP_SELL) ; and in the function itself

double StopLossLastPos(int op=-1,) like this?

No, it is not. You simply don't understand what a function is.

All subprograms can be divided into two classes - procedures and functions. If a subprogram doesn't have to return anything to the main program, then such a subprogram is called a procedure. If it is supposed to return something, then it is a function.

Imagine you have to calculate the square root of a number in various places in your code. Suppose you don't have a square root evaluation command in your language. So that you don't have to write a bunch of code calculating the square root, you write a subroutine (a function) which takes some value as input and outputs the square root of that value. Then, in the main program instead of calculating the square root you call your function, and it returns the value already calculated.

So, for your function to understand that it's a number, and not a string, or any other type of data, you need to list the types of parameters passed to it in brackets when declaring the function. For example, you wrote a subprogram MyKoren() that will return a value of type double. When you make the body of this function, in brackets you specify that the passed parameter will have the name MyValue and the type duble. The result will be that your function will look like this:

double MyKoren(double MyValue){

// здесь пишем код нашей подпрограммы, который вычислит квадратный корень из величины, которая лежит в переменной MyValue.

// Именно эта переменная запишет в себя то число, которое поступило на вход подпрограммы в момент её вызова.

double Rezult;

Rezult =......(MyValue).........;// вычисляем квадратный корень и результат заносим в переменную Rezult

return(Rezult);// возвращаем вычисленное значение в основную программу

}

Now that we've written the function, we call it in code:

double PeremennayaDljaKornja;

PeremennayaDljaKornja=(xzc+256)*(AZN+322);
PeremennayaDljaKornja=MyKoren(PeremennayaDljaKornja);
// теперь после вызова нашей функции в переменной "PeremennayaDljaKornja" окажется результат вычислени я квадратного корня из той величины, которая лежала
// в PeremennayaDljaKornja перед тем, как мы вызвали нашу функцию

Well, if you didn't describe our subroutine correctly, like this:

 double MyKoren(double MyValue=36){

// здесь пишем код нашей подпрограммы, который вычислит квадратный корень из величины, которая лежит в переменной MyValue.

// Именно эта переменная запишет в себя то число, которое поступило на вход подпрограммы в момент её вызова.

double Rezult;

Rezult =......(MyValue).........;// вычисляем квадратный корень и результат заносим в переменную Rezult

return(Rezult);// возвращаем вычисленное значение в основную программу

...................... return(Rezult); }

The result would be that the subroutine would always return value = 6 to us, because MyValue would always be equal to 36 and the root of 36 = 6

That's why we cannot initialize the function's parameter with the value in those brackets where these parameters are listed.

I will not edit your code anymore - you do not understand what you are doing - you obviously lack knowledge. You need to read a textbook, try and experiment with small code fragments. And do this until you have clarity in your hands - so that you understand WHAT you are doing with this or that line of code.

 
FreeLance:

You don't have to steal.

It's unlikely he stole it - it's more likely he stumbled across something already stolen and didn't even know it. :)
 
drknn:
It's unlikely he stole it - it's more likely he stumbled across something already stolen and didn't even know it. :)

Anything's possible. ;)

I just resent the double standard.

And the Pharisee interpreters...

 
FreeLance:

Anything's possible. ;)

I just resent the double standard.

And the Pharisee interpreters...


It's your own business. It's nothing personal.
 
Vinin:

It's your personal business. Nothing personal.

Explain the rules in more detail.

And let's do it all!

I'm all for it!

:)

-----

My personal opinion is that it's not just my personal need...

;)

 
drknn:

I'm not a worker, but I'm trying to write an Expert Advisor for the week I've been working on. I'm trying to write an EA for a job, but I've learned more than its name and application only a week ago, I don't know what it's for, but I figured it's hard to take things apart without knowing what they're for, so I decided to try and make something new, but of course you can't see everything, I just did the one thing I wanted to do - take the REMOTE ORDER OFF at the REMOTE price and it's no big deal. BUT THANK YOU ANYWAY FOR YOUR TIME,
 
Good evening everyone and have a good week ahead. I guess I'm being silly with the heat, actually the question is how do I define, put distance between lines in pips?
 

Good afternoon!

Does anyone know how to put a big fat dot on a graph if the correct coordinates are known?

 
inttehn:

Good afternoon!

Does anyone know how to put a big fat dot on a graph if the correct coordinates are known?

By creating an errow object where you have to select a symbol code or by using a label object
Reason: