You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
The TimeOpenLastPos() function.
This function returns the time of the last open position. Selection of positions to be taken into account is defined by external parameters:
Is there a bubble sorting function in the backroom
Not available, but it took me 10 minutes to make
ZS. Attached is a script to test the BubbleSort() function.The function BarsBetweenLastFractals().
This function returns the number of bars between the last two fractals or -1. The market instrument and timeframe from which the fractals are to be taken are specified by the parameters:
SecondsAfterCloseLastPos() function.
This function returns the number of seconds after the last position was closed. The selection of positions to be taken into account is specified by the parameters:
Hello
Some advice.
I have an EA which puts orders to both sides at a certain time
Please explain on your fingers how to make the second order be automatically deleted when the first one triggers.
Or tweak it
Thank you
Hello
Some advice.
I have an EA which puts orders to both sides at a certain time
Please explain on your fingers how to make the second order be automatically deleted when the first one triggers.
Or tweak it
Thank you
KimIV
Igor. Do you have enough fingers?
Hello
Some advice.
I have an EA which puts orders to both sides at a certain time
Please explain on your fingers how to make the second order be automatically deleted when the first one triggers.
Or tweak it
Thank you
First take the function number of orders in this branch and if it returns "== 1", "< 2" or "== odd number", then call the function from this branch "close orders".
KimIV
Igor. Do you have enough fingers?
Probably not... I only have two: index finger and grip... hee
First take the number of orders function in this branch, and then if it returns "== 1", "< 2" or "== odd number", then call the "close orders" function from this branch.
The function of the orders quantity will not work, because the EA is set differently for every pair. And it sets orders on different pairs at the same time. Then if four orders are placed for two pairs and one triggered, three of them are deleted and the opposite order for each is deleted.