Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 611
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
Good afternoon. Can you tell me what's wrong. I want to colour the Fibo levels in different colours, but they are not colored in any way. Below is the code of what I am doing. Thanks in advance for the help.
There is an answer on page 603.
Page 603 has the answer.
But why doesn't it work, since it seems to be spelled correctly!!!!
But why doesn't it work, since it seems to be spelled correctly!!!!
There was a discussion here. Please don't repeat the same question all over the forum.
//+-------------------------------------------------------------------------------------+
Can you add
when any order was closed on take profit, all pending and urgent orders should be closed.
SanNneK:
...
Can you add
When any order was closed on Take Profit, all pending and emergency orders should be closed.
This is a help for solving problems when you can not do it yourself, not an altruistic society.
If you need someone to write it for you, you're welcome to do it here.
@Artyom Trishkin I need to write code when any order reaches take profit, all other orders pending and usual closed, I do not need other advisors.
Start writing code. What you can't do, ask, show me in your code and they will help you.
I wrote code that when take profit of the first buy order triggers, all pending orders are closed, but it does not work, highlighted in blue what does not work
void start(){
//----
double Take1 = Ask+20 *Point;
double Take2 = Ask+0 *Point;
double Take3 = Ask-20 *Point;
double Take4 = Ask-40 *Point;
double Take5 = Ask-60 *Point;
double Stop = Bid-StopLoss *Point;
if(OrdersTotal()==0){
OrderSend(Symbol(),0,0.01,Ask,30,Stop,Take1, "sdsdasdadwadawd",0,0,CLR_NONE);
OrderSend(Symbol(),2,0.02,Ask-20*Point,30,Stop,Take2, "awda",0,0,CLR_NONE);
OrderSend(Symbol(),2,0.04,Ask-40*Point,30,Stop,Take3, "awdawd",0,0,CLR_NONE);
OrderSend(Symbol(),2,0.08,Ask-60*Point,30,Stop,Take4, "awdawd",0,0,CLR_NONE);
OrderSend(Symbol(),2,0.16,Ask-80*Point,30,Stop,Take5, "awdawdawda",0,0,CLR_NONE);
}
if(OP_BUY==Take1)
{
OrderDelete(2);
}
if(OP_BUY==Take1)
{
OrderDelete(3);
}
if(OP_BUY==Take1)
{
OrderDelete(4);
}
if(OP_BUY==Take1)
{
OrderDelete(5);
return(0);
}
}