Add a continuity function to my EA

MQL4 Experts C++

Job finished

Execution time 21 minutes
Feedback from employee
Excellent customer. thanks.
Feedback from customer
Great job, great programmer, happy to have reworked with you, thank you

Specification

Hello,
My EA is simple, When the preset sum is reached it cuts all my orders.
but the problem is that I have to manually re-enter a new sum for it to continue.
what I would like is when a sum is reached, that my equity account automatically goes to the previous sum...

Example

My value is (AccountEquity()>= 1400)
and when the sum of 1400 is reached the EA closes all orders and automatically goes to 1450
closes all orders and 1500 closes all orders and 1550 closes all orders ect if my value and 50.

Comple code:

//+------------------------------------------------------------------+
//|                    TakeProfit 1 |
//+------------------------------------------------------------------+

#property copyright ""
#property link      ""


                                       
extern double My_Money_Equity_Target=1400;  
                                         
int Slippage=5;                                        
int i;


//+------------------------------------------------------------------+
                                  
//+------------------------------------------------------------------+
int init()
  {
//---- 
   
//----
   return(0);
  }
//+------------------------------------------------------------------+
                               
//+------------------------------------------------------------------+
int deinit()
  {
//---- 
   
//----
   return(0);
  }
//+------------------------------------------------------------------+
                                         
//+------------------------------------------------------------------+


int start()
{
if (AccountEquity()>= 1400)

   {
    for(i=OrdersTotal()-1;i>=0;i--)
       {
       OrderSelect(i, SELECT_BY_POS);
       int type   = OrderType();
               
       bool result = false;
       switch(type)
          {
          //Close opened long positions
          case OP_BUY  : result = OrderClose(OrderTicket(),OrderLots(),MarketInfo(OrderSymbol(),MODE_BID),Slippage,clrNONE);
                         break;
               
          //Close opened short positions
          case OP_SELL : result = OrderClose(OrderTicket(),OrderLots(),MarketInfo(OrderSymbol(),MODE_ASK),Slippage,clrNONE);
                         break;
          //Close pending orders
            case OP_BUYLIMIT  :
            case OP_BUYSTOP   :
            case OP_SELLLIMIT :
            case OP_SELLSTOP  : result = OrderDelete( OrderTicket());
          }
          
          
       if(result == false)
    
       
          {
            Sleep(3000);
          }  
       }
      Print ("Account Profit ");
      return(0);
   }  
   
   Comment("Balance: ",AccountBalance(),", Account Equity: ",AccountEquity(),", Account Profit: ",AccountProfit(),
           "\nMy Account Equity Target: ",1400);
   
  return(0);
}

Responded

1
Developer 1
Rating
(590)
Projects
789
71%
Arbitration
9
33% / 33%
Overdue
22
3%
Free
2
Developer 2
Rating
(31)
Projects
42
26%
Arbitration
10
20% / 50%
Overdue
8
19%
Free
3
Developer 3
Rating
(3)
Projects
8
13%
Arbitration
10
10% / 70%
Overdue
2
25%
Free
4
Developer 4
Rating
(620)
Projects
680
57%
Arbitration
25
16% / 60%
Overdue
228
34%
Free
Similar orders
Hello, I have a physically trading keyboard and i want to connect it with tradelocker, mt4,mt5 and ctrader. People need to be able to open and close a position with the keyboard really fast. i need it on macos, windows and linux. (desktop) My competition is: www.magickeys.trade My goal is to be the number 1 to sell the keyboards + software. When people order a tradingkeyboard they will get a mail after the purchase
Job Title: Expert Advisor (EA) Developer for Forex Trading Job Description: I am seeking an experienced Expert Advisor (EA) developer to create a customized trading bot for the MetaTrader 4/5 platform. The bot will be designed to execute a sophisticated trading strategy that incorporates daily range calculations, cost averaging, and hedging with precise pip management. The successful candidate should have strong
I need an expert advisor based on MACD and MA signals. It must have check and handling of trade operations errors. The main criteria for opening and closing positions: ◇Both Main and Signal direction must be shown by Arrows which is going to be for buy and sell positions
I need an expert to help me with adding more features to my existing mt4 EA I think the addition I want added to this EA is fairly simple--but I don't really understand how programming works, Contact me for a long term work, This is not the only project, I will explain the features in the inbox, Let me know if you can do it
**Project Title:** Development of a Complex High-Performance EA for Step Index **Project Overview:** I need an advanced Expert Advisor (EA) for trading the Step Index on MetaTrader 5. The EA should use multiple indicators and advanced risk management techniques to enhance profitability and manage risks effectively. **Trading Strategy Details:** Indicators: - 50-period EMA - 200-period EMA - RSI with 14 periods - MACD
Hft live account 30 - 200 USD
i need a high frequency trading (hft) expert advisor, that can be used to trade on demo and live accounts icmarket and 8cap. The EA has to be highly profitable, giving daily profit. If a test version is available, please send, to foster a faster transaction. like the ones that pass prop firm and demo but adjustment where it work on live with low latency
Lihle's trades 30+ USD
``` //+------------------------------------------------------------------+ //| Hello World Expert Advisor | //| | //| This is a basic EA that buys and sells based on a simple | //| moving average crossover strategy. | //+------------------------------------------------------------------+ #property version "0.01" #property strict input int FastMA
Indicator in use: Bollinger Bands Mechanism (See diagrams provided for help) Sells: 1. Trigger candle: When candle low is above the top Bollinger band - accurate to the lowest point scale (e.g. On EURUSD if candle low is 1.07915 and the value of top bollinger is 1.07914 - this is a sell signal; or if on Futures if the increment is .25 or .10 then this is used) 2. Enter sell ONLY on the next candle if price breaks
CPI ROBOKING 30+ USD
*Strategy: CPI-Based Trading* *Instruments:* XAUUSD (Gold), UsTech100 (Nasdaq 100), USDJPY *CPI Release:* 1. *Higher-than-expected CPI:* - XAUUSD: SELL (Gold prices may drop due to potential rate hike) - UsTech100: SELL (Tech stocks may drop due to potential rate hike) - USDJPY: BUY (USD may strengthen due to potential rate hike) 2. *Meets or lower-than-expected CPI:* - XAUUSD: BUY (Gold prices may rise due
I'm looking for a quote from a developer who can compile this source code as DLL file so that it works on Forex Tester 5 They are all open source trading view indicators. Forextester 5 have advised that custom indicators in C++ or Delphi programme language are compatible with them

Project information

Budget
30+ USD
VAT (20%): 6 USD
Total: 36 USD
For the developer
27 USD
Deadline
to 10 day(s)