Only places trades in strategy tester

To add comments, please log in or register
SirFency
173
SirFency  

Could someone please help point out why this EA I have been working on will not place trades live. It seems to place them in the strategy tester fine.

Files:
William Roeder
20207
William Roeder  
  1. double lookBackEURGBP = iOpen("EURGBP",0,1);
    double lookBackEURAUD = iOpen("EURAUD",0,1);
    On MT4: Unless the current chart is that specific pair/TF referenced, you must handle 4066/4073 errors.
              Download history in MQL4 EA - MQL4 and MetaTrader 4 - MQL4 programming forum

  2. Don't assume that Time[i] == iTime(otherPair,TF, i) always use iBarShift.

  3. int MagicNumberGenerator()
    No need for multiple MNs per symbol.
              Symbol Doesn't equal Ordersymbol when another currency is added to another seperate chart . - MQL4 and MetaTrader 4 - MQL4 programming forum

  4. Use the debugger or print out your variables, including _LastError and find out why.
SirFency
173
SirFency  
whroeder1:
  1. On MT4: Unless the current chart is that specific pair/TF referenced, you must handle 4066/4073 errors.
              Download history in MQL4 EA - MQL4 and MetaTrader 4 - MQL4 programming forum

  2. Don't assume that Time[i] == iTime(otherPair,TF, i) always use iBarShift.

  3. No need for multiple MNs per symbol.
              Symbol Doesn't equal Ordersymbol when another currency is added to another seperate chart . - MQL4 and MetaTrader 4 - MQL4 programming forum

  4. Use the debugger or print out your variables, including _LastError and find out why.

Thank you. aside from taking a look at the things you mentioned. Having an extra set of eyes on this has made me realize when I changed this from an indicator to an EA I changed all my arrays to variables and in doing so broke my lookback calculation. Once I fixed it I started getting trades.

To add comments, please log in or register