open orders with 10pip gap

 

please help me with handy code to open position and open another one after 10pips.thanks


see what i have tried but no success with the code please help

if( ma1 > Ask + (10*Point)&& CurrentTime != Time[1])  {      Opn_B=true;     }
 
Create a pending order. Market order is not possible.
 
deysmacro:
Create a pending order. Market order is not possible.

Deysmarco what I mean is not pending order but example when i open buy! wait 10pips before another buy other is opened
 
dan100:

Deysmarco what I mean is not pending order but example when i open buy! wait 10pips before another buy other is opened

What you want can be done but requires more coding in it to make it works.
 
deysmacro:
What you want can be done but requires more coding in it to make it works.

Please can you help me with that.
 
see picture10pip open of what i mean to code, please assist me with right way of doing it please.
 

please i need your assistance



dan100:
see picture of what i mean to code, please assist me with right way of doing it please.
 
  1. Find the open trade with the highest open price.
  2. If market hasn't reached the price + 10 pips, return
  3. open a new order.
  4. learn to code it, or pay someone. We're not going to code it FOR you. We are willing to HELP you when you post your attempt (using SRC) and the nature of your problem.
 
WHRoeder:
  1. Find the open trade with the highest open price.
  2. If market hasn't reached the price + 10 pips, return
  3. open a new order.
  4. learn to code it, or pay someone. We're not going to code it FOR you. We are willing to HELP you when you post your attempt (using SRC) and the nature of your problem.




please WHRoeder: i write my codes but not perfect though i try to learn more ,please if you can help me please i just want to put it

into my existing code please help. i have tried yet  not perfectly coded, though you have giving me formular. i have succeded in getting the high but its

not opening orders 10pips as i want.please help me with the 10pips order open bellow is what i have done so far.



 
 if(ma1 > Price + (10*Point) && CurrentTime != Time[1])
  {
      Opn_S=true;
     } 
     else 
   if(ma1 < Price + (10*Point)&& CurrentTime != Time[1]) 
      {
      Opn_S=false;
     }
 
  1. I asked you to show your code that finds the highest open price. You didn't.
  2. I asked you to show your code that tests if the market has or has not reached that price + 10 pips. You didn't. You posted code that determines if a moving average (ma1) is above a price (Price) by 10 points. A pip is 10 points on a 5 digit broker.
  3. Your code
     Your code simplified.
     if(ma1 > Price + (10*Point) && CurrentTime != Time[1])
      {
          Opn_S=true;
         } 
         else 
       if(ma1 < Price + (10*Point)&& CurrentTime != Time[1]) 
          {
          Opn_S=false;
         }
    Opn_S= ma1 > Price + (10*Point) && CurrentTime != Time[1];
    
    Also what if CurrentTime == Time[1]? What is the value of Opn_S then?