Breakeven stoploss

MQL4 Indicateurs Experts

Spécifications

As you can see from the EA I have attached. The stop moves to breakeven + 5pips when the price moves in the direction of profit by 7 pips + 5 pips. The issue with this stop is it moves from entry price(openorderprice) due to slippage sometimes entry price is not always candlestick open(which is when the trade is supposed to open.


I want the code changed so that breakeven stoploss to be set from candlestick open.


he stoploss code I am using at the moment is shown below.


void TrailingStopBE(int type, double profit, double add) //set Stop Loss to open price if in profit

  {

   int total = OrdersTotal();

   profit = NormalizeDouble(profit, Digits());

   for(int i = total-1; i >= 0; i--)

     {

      while(IsTradeContextBusy()) Sleep(100);

      if(!OrderSelect(i, SELECT_BY_POS, MODE_TRADES)) continue;

      if(OrderMagicNumber() != MagicNumber || OrderSymbol() != Symbol() || OrderType() != type) continue;

      RefreshRates();

      if((type == OP_BUY && Bid > OrderOpenPrice() + profit && (NormalizeDouble(OrderStopLoss(), Digits()) <= 0 || OrderOpenPrice() > OrderStopLoss()))

      || (type == OP_SELL && Ask < OrderOpenPrice() - profit && (NormalizeDouble(OrderStopLoss(), Digits()) <= 0 || OrderOpenPrice() < OrderStopLoss())))

         myOrderModify(OrderTicket(), OrderOpenPrice() + add, 0);


 TrailingStopBE(OP_BUY, 70 * myPoint, 0 + 50 * myPoint); //Trailing Stop = go break even + fixed value

   TrailingStopBE(OP_SELL, 70 * myPoint, 0 - 50 * myPoint); //Trailing Stop = go break even - fixed value

Dossiers :

Répondu

1
Développeur 1
Évaluation
(600)
Projets
935
46%
Arbitrage
31
39% / 29%
En retard
93
10%
Gratuit
2
Développeur 2
Évaluation
(169)
Projets
204
30%
Arbitrage
25
40% / 44%
En retard
12
6%
Gratuit
3
Développeur 3
Évaluation
(93)
Projets
133
35%
Arbitrage
13
38% / 31%
En retard
32
24%
Gratuit
4
Développeur 4
Évaluation
(24)
Projets
28
32%
Arbitrage
1
0% / 0%
En retard
0
Gratuit
5
Développeur 5
Évaluation
(19)
Projets
35
26%
Arbitrage
10
30% / 70%
En retard
5
14%
Gratuit
6
Développeur 6
Évaluation
(111)
Projets
141
44%
Arbitrage
19
16% / 53%
En retard
20
14%
Chargé
7
Développeur 7
Évaluation
(21)
Projets
24
17%
Arbitrage
15
20% / 40%
En retard
6
25%
Gratuit
8
Développeur 8
Évaluation
(26)
Projets
29
45%
Arbitrage
0
En retard
1
3%
Gratuit
9
Développeur 9
Évaluation
(65)
Projets
85
26%
Arbitrage
23
22% / 48%
En retard
24
28%
Travail
10
Développeur 10
Évaluation
(87)
Projets
114
26%
Arbitrage
7
29% / 57%
En retard
5
4%
Gratuit
Commandes similaires
Hello, am in need of a developer that can help in developing a trading bot that can effectively navigate the foreign exchange (Forex) market or other financial markets to generate passive income. My objective is to create a sophisticated algorithmic trading system that can consistently produce profitable trades with minimal manual intervention. I am seeking a reliable and efficient solution that can be tailored to my
am looking for who help me convert tradingview indicator to mt5 car trading strategy and make sure you are an expert before u apply to this and also my budget for this is 30$ so the name of the indicator is Breaker Blocks with Signals (LuxAlgo) ### 1. ** Entry Condition **: - ** For Long**: The trade is entered **after BB + ** is confirmed. - ** For Short *: The trade is entered **after BB -* is confirmed. ### 2nd
I have a custom MT4 indicator that I need converted to MT5. I'll share the source code with the applicants. Please only apply if you have vast experience in converting complex indicators successfully to MT5, and making sure that the MT5 version functions exactly the same as the MT4 version
I need an expert to help me convert chopzone traingview pinescript to mt4, I need an expert to get it done for me on between 1 to 2 days i hope this will be done by then, i will attach the file and my budget is $30 as of minimum here
Looking for someone to edit/optimize and existing NN (neural network) in my EA so it is more compatible/profitable with the multiple strategies. The expert advisor is a portfolio expert advisor consisting of 33 separate advisors/strategies compiled into one. A NN has been added to the EA but it does not compliment or help the EA's performance. I've attached the original EA (without NN) as well as the EA with the NN
Need to modify the ea to take trades based on an indicator. indicator and ea source code available. Variable inputs of indicator to be added. Buy Amount for Profit (+ve $value ) Buy Amount for Loss (-ve $value ) Sell Amount for Profit (+ve $value ) Sell Amount for Loss (-ve $value )
Procuro programador que consiga modificar essas estratégias, com a mesma capacidade de alteração das suas funcionalidades. Reitero, não consegui contato com o programador da fonte, nem mesmo mandando diversas mensagens no telegram! br.tradingview.com/script/PfpFNXyI-Braid-Filter/ br.tradingview.com/script/kv8N05R7-AlphaTrend-Screener/ Ambos os indicadores precisam agir em conjunto, tanto para as funcionalidades em
--- ### Basic Rules for You 1. **Time Management**: - All tasks should be completed within the agreed-upon timeframe. Clear deadlines will be set, and it's essential to adhere to them to ensure smooth progress. 2. **Fixed Budget**: - The budget for this project is fixed. Please ensure that all work done remains within this budget. Any additional costs must be discussed and agreed upon before proceeding. 3
CORREÇÃO NOTIFICAÇÕES Ø O indicador muda a cor dos candles e da MA200 quando ocorre as entradas e é somente nesse momento que ele deve enviar notificação de entrada porem está enviando em outros momentos que não atende as condições conforme imagem abaixo. Ø Sempre que abro o MT5, mudo o time frame ou a plataforma perde conexão o indicador me envia notificações de entradas passadas, o indicador deve enviar
Hi I have an indicator that i have tried to create an EA with, this is a simple EA that should have bought on green indicator value if previous candle indicator value was yellow. Then it should have sold when indicator value was red with previous value being yellow. Now, i would not say that i am a coder, by any stretch of the imagination, but something this simple should have been easy, instead, the EA would open

Informations sur le projet

Budget
30+ USD
TVA (23%): 6.9 USD
Total: 36.9 USD
Pour le développeur
27 USD
Délais
de 1 à 3 jour(s)