I've been reading for three days now. :=( It's easier in php, but I can't understand it here.
I agree with the moderator, it's better to mark orders/positions than to compare open prices. In addition to magic number, you can use check for comments. You can write the opening price in the comment (e.g. "EURUSD 1,251").
paladin80: In addition to the magic number, comment checking can also be used. The opening price can be written in the commentary (e.g. "EURUSD, 1.251").
This is dangerous: the server can change/add comments to orders under certain conditions, so in this case you risk getting caught unawares. Even in the tester, when something like "[sl]" is attached to the comment.
Offset relative to the current bar deep into history. Returns 0.
There is no second coordinate.
That's not it or I don't get it.
Eh... I don't need coordinates, we pass the name of line object and bar number (0 or 1, as you wrote) into the function, the output is the line value on this bar. We compare it to the price... Or I don't understand the problem?
Can you advise a newcomer: does the include file need to be compiled?
no
What is the difference between a include file and a library?
The first one does not need to be compiled, because it is included into the program code itself, the second one does, because its functions are included from the ex4-file
Where is it better to store functions: in a include file or in a library and why?
For your own use, it would probably be better in mqh; if you need to distribute the library and don't want to open the source code, then ex4. The function call from ex4 is quite slow, but if the performance is not critical, then in principle, whatever
alsu: Eh... I don't need coordinates, we pass the name of line object and bar number (0 or 1, as you wrote) into the function, the output is the value of the line on this bar. We compare it to the price... Or I don't understand the problem?
s="doun"; if (ObjectFind(s)==0) {ObjectDelete(s);} ObjectCreate(s,OBJ_TRENDBYANGLE,0,Time[W1],High[W1]); ObjectSet(s,OBJPROP_ANGLE,310);
Somebody write a normal tester, multi-currency and with floating spreads))))
ps and also with real ticks, blackjack and whores
Thanks everyone for the tips and help)))) If someone will write a tester and share, I think there will be a lot of grateful people.... I do not have enough knowledge for that yet.... learn, learn and learn...))))
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
I've been reading for three days now. :=( It's easier in php, but I can't understand it here.
In addition to the magic number, comment checking can also be used. The opening price can be written in the commentary (e.g. "EURUSD, 1.251").
Help a self-taught programmer.
Built a trend line with standard tools.
The first coordinate of the trend line is known, but the second coordinate is unresolved. It is mandatory for the calculation formula.
It is present on the chart when it is selected with the mouse. Is there any way to determine it?
We have some other ways of determining it.
Preferably share the code if you can.
Help a self-taught programmer.
Built a trend line with standard tools.
The first coordinate is known, but the second one is unresolved. It is mandatory for the calculation formula.
It is present on the chart when the mouse is selected. Is there any way to determine it?
Or approach it in some other way.
Preferably share the code if you can.
Since you've already built it, how about ObjectGetValueByShift()?
Offset relative to the current bar deep into history. Returns 0.
There is no second coordinate.
That's not it or I don't get it.
Hello!
Can you advise a newcomer on whether a include file needs to be compiled?
What is the difference between a include file and a library? Where is it better to store functions: in a include file or in a library and why?
Offset relative to the current bar deep into history. Returns 0.
There is no second coordinate.
That's not it or I don't get it.
Hello!
Can you advise a newcomer: does the include file need to be compiled?
no
What is the difference between a include file and a library?
The first one does not need to be compiled, because it is included into the program code itself, the second one does, because its functions are included from the ex4-file
Where is it better to store functions: in a include file or in a library and why?
For your own use, it would probably be better in mqh; if you need to distribute the library and don't want to open the source code, then ex4. The function call from ex4 is quite slow, but if the performance is not critical, then in principle, whatever
Eh... I don't need coordinates, we pass the name of line object and bar number (0 or 1, as you wrote) into the function, the output is the value of the line on this bar. We compare it to the price... Or I don't understand the problem?
s="doun";
if (ObjectFind(s)==0) {ObjectDelete(s);}
ObjectCreate(s,OBJ_TRENDBYANGLE,0,Time[W1],High[W1]);
ObjectSet(s,OBJPROP_ANGLE,310);
double price=ObjectGetValueByShift("doun", 1);
Comment(price);returns 0.
line is present.
Somebody write a normal tester, multi-currency and with floating spreads))))
ps and also with real ticks, blackjack and whores