Any questions from newcomers on MQL4 and MQL5, help and discussion on algorithms and codes - page 1000
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 Expert Advisor places only one order per algorithm, consider Sell:
SellOpen = (AC<0.0 && RSI<30 && Close[2]>Open[2] && Close[1]>Open[1] && Low[2]<Low[1] );
How to write the code so that it would continue placing orders while the condition AC<0.0 is present
Check if there is already something in the market:
If the amount is more than 0, it means that there is an opening according to the algorithm.
See if there is already something in the market:
If the number is greater than 0, then there is an opening according to the algorithm, then add by condition
Two errors are given
//--------------------------
double profit = 0;
int countBuy=0, countSell=0;
for(int i = 0; i < OrdersTotal(); i++)
{
if(OrderSelect(i, SELECT_BY_POS) && OrderSymbol() == _Symbol && OrderMagicNumber() == MAGIC)
{
if(OrderType() < 2)
profit += OrderProfit()+OrderCommission()+OrderSwap();
if(OrderType() == 0)
countBuy++;
if(OrderType() == 1)
countSell++;
}
}
if(countBuy>0 && AC<0.0) -tu OpenOrderBuy(100);
if(countSell>0 && AC<0.0) -then- OpenOrderSell(100);
//------------------
'OpenOrderBuy' - function not defined SA2.mq4 102 29
'OpenOrderSell' - function not defined SA2.mq4 104 30
Where the error is blinking I wrote -there
Two errors are given
...
Where the error is blinking I have written -too-.
Please insert the code (and not only) correctly:
Please insert the code (and not only) correctly:
I don't get it.?
Two errors are given.
This one you can fix yourself - gave an abstract application
This you can do for yourself - gave an abstract application
NO DECOMPILING ALLOWED!
With code like that:
I can't get into programming.
Be carefulwith that kind of code. You could get banned even without knowledge of programming. It has all the hallmarks of a decompiled
Be careful with this code. You may get banned without knowledge of programming. It has all the hallmarks of a decompiled
This is the original test EA I replaced the other signs with Li le . No one will understand anything in this one.
Fix it yourself - gave an abstract application
I don't know how to fix it.