error 10013
Sarsali:
Hi
I wrote a EA But buy order don't execute and i get this error. pl help !
Error:
2014.05.12 11 36.000 2014.04.04 05:01:06 Function: BuyOrder3 Error: 10013 Invalid request
2014.05.12 11 36.000 2014.04.04 05:01:07 failed exchange buy 0.20 EURUSD at 1.37150 sl: 1.36950 tp: 1.37450 [Invalid request]
Thank You
Try to change this line :
//--- prepare a request MqlTradeRequest request={0};
angevoyageur:
that's right. Thank you a lot angevoyageur Try to change this line :
I have the same problem.
Pleasehelp me.
2021.01.11 11:16:55.474 EA_Sophie (AUDUSD.R2.5pip,M1) Ordem de Compra - com falha. ResultRetcode: 10013, RetcodeDescription: invalid request
input double lote = 0.01; //Volume input double StopLoss = 0.0003; //Stop Loss input double TakeProfit = 0.0004; //Take Profit input bool Breakeven = true; //Active Break Even input double Trigger_Breakeven = 0.00/035; //Trigger Break Even input bool TrailingStop = true; //Active Trailing Stop input double Trigger_TrailingStop = 0.00035; //Trigger Trailing Stop input double Step_TrailingStop = 0.00035; //Step Trailing Stop input ulong MagicNumber = 80008; //Magic Number input ulong DesvPoints = 0; //Desvio em Pontos input ENUM_ORDER_TYPE_FILLING Fill = ORDER_FILLING_FOK; //Order Filling (Fill or Kill / Imed. or Cancel / Exec) double PRC; //Preço normalizado double STL; //StopLoss normalizado double TKP; //TakeProfit normalizado PRC = NormalizeDouble(ultimoTick.ask, _Digits); STL = NormalizeDouble(PRC - StopLoss, _Digits); TKP = NormalizeDouble(PRC + TakeProfit, _Digits); if(trade.Buy(lote, _Symbol, PRC, STL, TKP, "")) { Print("Ordem de Compra AUTOMÁTICA - RENKO - sem falha. ResultRetcode: ", trade.ResultRetcode(), ", RetcodeDescription: ", trade.ResultRetcodeDescription()); } else { Print("Ordem de Compra AUTOMÁTICA - RENKO - com falha. ResultRetcode: ", trade.ResultRetcode(), ", RetcodeDescription: ", trade.ResultRetcodeDescription()); }

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
Hi
I wrote a EA But buy order don't execute and i get this error. pl help !
Error:
2014.05.12 11 36.000 2014.04.04 05:01:06 Function: BuyOrder3 Error: 10013 Invalid request
2014.05.12 11 36.000 2014.04.04 05:01:07 failed exchange buy 0.20 EURUSD at 1.37150 sl: 1.36950 tp: 1.37450 [Invalid request]
Thank You