SELL STOP WHEN BUY STOP BECOME BUY

 

Hello.. May somebody help me how to code, 

If Buy Stop triggered become BUY, Sell Stop appeared, and that Sell Stop triggered become Sell, New Buy Stop appeared.

 
  1. Help you with what? You haven't stated a problem, you stated a want. Show us your attempt (using the CODE button) and state the nature of your problem.
              No free help 2017.04.21

    Or pay someone. Top of every page is the link Freelance.
              Hiring to write script - General - MQL5 programming forum 2018.05.12

    We're not going to code it for you (although it could happen if you are lucky or the problem is interesting).
              No free help 2017.04.21

  2. if( count_orders(OP_BUY)  > 0 && count_Orders(OP_SELLSTOP) == 0) open_pending_order(OP_SELLSTOP);
    if( count_orders(OP_SELL) > 0 && count_Orders(OP_BUYSTOP)  == 0) open_pending_order(OP_BUYSTOP);
    Writing the functions are left as an exercise for the reader.