Amps

Tuesday, February 23, 2016

Moving Average Activate Open and Close order Function MQL4

Moving Average Activate Open and Close order Function MQL4

Basic Function Moving Average Multi order EA Example MQL4

bool IsTradeAllowed
string symbol
datetime Time to check status

Full code on this part OnTick

//+------------------------------------------------------------------+
//| OnTick function                                                  |
//+------------------------------------------------------------------+
void OnTick()
  {
//--- check for history and trading
   if(Bars<100 || IsTradeAllowed()==false)
      return;
//--- calculate open orders by current symbol
   if(CalculateCurrentOrders(Symbol())==0) CheckForOpen();
   else                                    CheckForClose();
//---
  }
//+------------------------------------------------------------------+

Finish Moving Average EA coding MQL4

1 comment:

  1. As reported by Stanford Medical, It's in fact the ONLY reason this country's women live 10 years longer and weigh an average of 19 kilos less than us.

    (And actually, it really has NOTHING to do with genetics or some hard exercise and absolutely EVERYTHING to do with "HOW" they eat.)

    BTW, I said "HOW", not "what"...

    TAP on this link to discover if this quick quiz can help you release your true weight loss potential

    ReplyDelete