Waddah Attar Win

Profit factor:
1.89
Orders Execution
It automatically opens orders when conditions are reachedChecks for the total of open ordersIt Closes Orders by itself
6 Views
0 Downloads
0 Favorites
Waddah Attar Win
#property link      "waddahattar@hotmail.com"
 
extern int     Step=120;
extern double  FirstLot=0.1;
extern double  IncLot=0;
extern double  MinProfit=450;
extern int     Magic = 2008;

double gLotSell=0;
double gLotBuy=0;
double LSP,LBP;

int init()
{
  Comment("Waddah Attar Win");
  GlobalVariableSet("OldBalance",AccountBalance());
  return(0);
}
int deinit()
{
  Comment("");
  return(0);
}
int start()
{
  double i;
  double sl,p;

  if (AccountEquity()>=GlobalVariableGet("OldBalance")+MinProfit)
  {
    DeletePendingOrders(Magic);
    CloseOrders(Magic);
    GlobalVariableSet("OldBalance",0);
  }

  GlobalVariableSet("OldBalance",AccountBalance());

  if (MyOrdersTotal(Magic)==0)
  {
    OrderSend(Symbol(),OP_BUYLIMIT,FirstLot,Ask-Step*Point,3,0,0,"",Magic,0,Green);
    OrderSend(Symbol(),OP_SELLLIMIT,FirstLot,Bid+Step*Point,3,0,0,"",Magic,0,Red);
  }

  LSP=GetLastSellPrice(Magic);
  LBP=GetLastBuyPrice(Magic);
  
  if((LSP-Bid)<=5*Point)
  {
    OrderSend(Symbol(),OP_SELLLIMIT,gLotSell+IncLot,LSP+Step*Point,3,0,0,"",Magic,0,Red);
  }

  if((Ask-LBP)<=5*Point)
  {
    OrderSend(Symbol(),OP_BUYLIMIT,gLotBuy+IncLot,LBP-Step*Point,3,0,0,"",Magic,0,Red);
  }

  return(0);
}

int DeletePendingOrders(int Magic)
{
  int total  = OrdersTotal();
  
  for (int cnt = total-1 ; cnt >= 0 ; cnt--)
  {
    OrderSelect(cnt,SELECT_BY_POS,MODE_TRADES);
    if (OrderMagicNumber() == Magic && OrderSymbol()==Symbol() && (OrderType()!=OP_BUY || OrderType()!=OP_SELL))
    {
      OrderDelete(OrderTicket());
    }
  }
  return(0);
}

int CloseOrders(int Magic)
{
  int total  = OrdersTotal();
  
  for (int cnt = total-1 ; cnt >= 0 ; cnt--)
  {
    OrderSelect(cnt,SELECT_BY_POS,MODE_TRADES);
    if (OrderMagicNumber() == Magic && OrderSymbol()==Symbol())
    {
      if (OrderType()==OP_BUY)
      {
        OrderClose(OrderTicket(),OrderLots(),Bid,3);
      }
      
      if (OrderType()==OP_SELL)
      {
        OrderClose(OrderTicket(),OrderLots(),Ask,3);
      }
    }
  }
  return(0);
}

int MyOrdersTotal(int Magic)
{
  int c=0;
  int total  = OrdersTotal();

  for (int cnt = 0 ; cnt < total ; cnt++)
  {
    OrderSelect(cnt,SELECT_BY_POS,MODE_TRADES);
    if (OrderMagicNumber() == Magic && OrderSymbol()==Symbol())
    {
      c++;
    }
  }
  return(c);
}

double GetLastBuyPrice(int Magic)
{
  int total=OrdersTotal()-1;

  for (int cnt = total ; cnt >=0 ; cnt--)
  {
    OrderSelect(cnt,SELECT_BY_POS,MODE_TRADES);
    if (OrderMagicNumber() == Magic && OrderSymbol()==Symbol() && (OrderType()==OP_BUYLIMIT || OrderType()==OP_BUY))
    {
      gLotBuy=OrderLots();
      return(OrderOpenPrice());
      break;
    }
  }
  return(0);
}

double GetLastSellPrice(int Magic)
{
  int total=OrdersTotal()-1;

  for (int cnt = total ; cnt >=0 ; cnt--)
  {
    OrderSelect(cnt,SELECT_BY_POS,MODE_TRADES);
    if (OrderMagicNumber() == Magic && OrderSymbol()==Symbol() && (OrderType()==OP_SELLLIMIT ||OrderType()==OP_SELL))
    {
      gLotSell=OrderLots();
      return(OrderOpenPrice());
      break;
    }
  }
  return(100000);
}

Profitability Reports

USD/CAD Jul 2025 - Sep 2025
6.50
Total Trades 77
Won Trades 54
Lost trades 23
Win Rate 70.13 %
Expected payoff 29.78
Gross Profit 2710.13
Gross Loss -416.94
Total Net Profit 2293.19
-100%
-50%
0%
50%
100%
USD/CAD Jul 2025 - Sep 2025
4.54
Total Trades 84
Won Trades 55
Lost trades 29
Win Rate 65.48 %
Expected payoff 25.88
Gross Profit 2787.28
Gross Loss -613.68
Total Net Profit 2173.60
-100%
-50%
0%
50%
100%
NZD/USD Jul 2025 - Sep 2025
3.74
Total Trades 65
Won Trades 43
Lost trades 22
Win Rate 66.15 %
Expected payoff 26.62
Gross Profit 2362.70
Gross Loss -632.20
Total Net Profit 1730.50
-100%
-50%
0%
50%
100%
NZD/USD Jul 2025 - Sep 2025
3.74
Total Trades 65
Won Trades 42
Lost trades 23
Win Rate 64.62 %
Expected payoff 26.58
Gross Profit 2359.80
Gross Loss -631.80
Total Net Profit 1728.00
-100%
-50%
0%
50%
100%
USD/CHF Jul 2025 - Sep 2025
3.38
Total Trades 92
Won Trades 58
Lost trades 34
Win Rate 63.04 %
Expected payoff 36.07
Gross Profit 4711.78
Gross Loss -1393.10
Total Net Profit 3318.68
-100%
-50%
0%
50%
100%
USD/CHF Jul 2025 - Sep 2025
3.13
Total Trades 93
Won Trades 58
Lost trades 35
Win Rate 62.37 %
Expected payoff 35.66
Gross Profit 4870.59
Gross Loss -1554.22
Total Net Profit 3316.37
-100%
-50%
0%
50%
100%
GBP/CAD Jul 2025 - Sep 2025
2.80
Total Trades 164
Won Trades 105
Lost trades 59
Win Rate 64.02 %
Expected payoff 24.78
Gross Profit 6324.01
Gross Loss -2260.80
Total Net Profit 4063.21
-100%
-50%
0%
50%
100%
AUD/USD Jul 2025 - Sep 2025
2.60
Total Trades 60
Won Trades 40
Lost trades 20
Win Rate 66.67 %
Expected payoff 27.27
Gross Profit 2657.70
Gross Loss -1021.50
Total Net Profit 1636.20
-100%
-50%
0%
50%
100%
GBP/USD Jul 2025 - Sep 2025
2.59
Total Trades 181
Won Trades 117
Lost trades 64
Win Rate 64.64 %
Expected payoff 27.36
Gross Profit 8056.30
Gross Loss -3104.80
Total Net Profit 4951.50
-100%
-50%
0%
50%
100%
AUD/USD Jul 2025 - Sep 2025
2.59
Total Trades 60
Won Trades 40
Lost trades 20
Win Rate 66.67 %
Expected payoff 27.21
Gross Profit 2658.20
Gross Loss -1025.30
Total Net Profit 1632.90
-100%
-50%
0%
50%
100%
GBP/USD Jul 2025 - Sep 2025
2.59
Total Trades 181
Won Trades 117
Lost trades 64
Win Rate 64.64 %
Expected payoff 27.36
Gross Profit 8056.30
Gross Loss -3104.80
Total Net Profit 4951.50
-100%
-50%
0%
50%
100%
USD/JPY Jul 2025 - Sep 2025
2.49
Total Trades 246
Won Trades 164
Lost trades 82
Win Rate 66.67 %
Expected payoff 23.49
Gross Profit 9654.67
Gross Loss -3876.14
Total Net Profit 5778.53
-100%
-50%
0%
50%
100%
USD/JPY Jan 2025 - Jul 2025
2.39
Total Trades 1043
Won Trades 695
Lost trades 348
Win Rate 66.63 %
Expected payoff 22.20
Gross Profit 39761.74
Gross Loss -16608.26
Total Net Profit 23153.48
-100%
-50%
0%
50%
100%
USD/JPY Jul 2025 - Sep 2025
2.25
Total Trades 256
Won Trades 167
Lost trades 89
Win Rate 65.23 %
Expected payoff 21.40
Gross Profit 9855.06
Gross Loss -4376.02
Total Net Profit 5479.04
-100%
-50%
0%
50%
100%
GBP/CAD Oct 2024 - Jan 2025
1.89
Total Trades 224
Won Trades 0
Lost trades 0
Win Rate 0.00 %
Expected payoff 18.36
Gross Profit 8734.49
Gross Loss -4622.13
Total Net Profit 4112.36
-100%
-50%
0%
50%
100%
GBP/AUD Jul 2025 - Sep 2025
1.60
Total Trades 207
Won Trades 131
Lost trades 76
Win Rate 63.29 %
Expected payoff 13.33
Gross Profit 7341.98
Gross Loss -4582.23
Total Net Profit 2759.75
-100%
-50%
0%
50%
100%
GBP/CAD Jul 2025 - Sep 2025
1.59
Total Trades 142
Won Trades 79
Lost trades 63
Win Rate 55.63 %
Expected payoff 14.17
Gross Profit 5398.70
Gross Loss -3387.02
Total Net Profit 2011.68
-100%
-50%
0%
50%
100%
GBP/AUD Jul 2025 - Sep 2025
1.58
Total Trades 207
Won Trades 132
Lost trades 75
Win Rate 63.77 %
Expected payoff 13.02
Gross Profit 7361.96
Gross Loss -4666.38
Total Net Profit 2695.58
-100%
-50%
0%
50%
100%
EUR/USD Jul 2025 - Sep 2025
0.89
Total Trades 17
Won Trades 8
Lost trades 9
Win Rate 47.06 %
Expected payoff -6178.72
Gross Profit 843944.80
Gross Loss -948983.00
Total Net Profit -105038.20
-100%
-50%
0%
50%
100%
NZD/USD Jan 2025 - Jul 2025
0.61
Total Trades 157
Won Trades 85
Lost trades 72
Win Rate 54.14 %
Expected payoff -25.72
Gross Profit 6410.00
Gross Loss -10447.60
Total Net Profit -4037.60
-100%
-50%
0%
50%
100%
GBP/CAD Jan 2025 - Jul 2025
0.55
Total Trades 211
Won Trades 92
Lost trades 119
Win Rate 43.60 %
Expected payoff -37.81
Gross Profit 9723.76
Gross Loss -17702.39
Total Net Profit -7978.63
-100%
-50%
0%
50%
100%
GBP/AUD Jan 2025 - Jul 2025
0.45
Total Trades 191
Won Trades 85
Lost trades 106
Win Rate 44.50 %
Expected payoff -42.35
Gross Profit 6640.75
Gross Loss -14729.56
Total Net Profit -8088.81
-100%
-50%
0%
50%
100%
USD/CHF Jan 2025 - Jul 2025
0.32
Total Trades 112
Won Trades 57
Lost trades 55
Win Rate 50.89 %
Expected payoff -71.44
Gross Profit 3723.14
Gross Loss -11724.55
Total Net Profit -8001.41
-100%
-50%
0%
50%
100%
AUD/USD Jan 2025 - Jul 2025
0.06
Total Trades 140
Won Trades 88
Lost trades 52
Win Rate 62.86 %
Expected payoff -7735.75
Gross Profit 63052.90
Gross Loss -1146057.80
Total Net Profit -1083004.90
-100%
-50%
0%
50%
100%
EUR/USD Jan 2025 - Jul 2025
0.01
Total Trades 136
Won Trades 85
Lost trades 51
Win Rate 62.50 %
Expected payoff -6992.74
Gross Profit 6163.50
Gross Loss -957176.50
Total Net Profit -951013.00
-100%
-50%
0%
50%
100%
AUD/USD Oct 2024 - Jan 2025
0.00
Total Trades 37
Won Trades 0
Lost trades 0
Win Rate 0.00 %
Expected payoff -225.30
Gross Profit 0.00
Gross Loss -8336.10
Total Net Profit -8336.10
-100%
-50%
0%
50%
100%
GBP/USD Oct 2024 - Jan 2025
0.00
Total Trades 35
Won Trades 0
Lost trades 35
Win Rate 0.00 %
Expected payoff -205.80
Gross Profit 0.00
Gross Loss -7203.00
Total Net Profit -7203.00
-100%
-50%
0%
50%
100%
NZD/USD Oct 2024 - Jan 2025
0.00
Total Trades 39
Won Trades 0
Lost trades 39
Win Rate 0.00 %
Expected payoff -239.00
Gross Profit 0.00
Gross Loss -9321.00
Total Net Profit -9321.00
-100%
-50%
0%
50%
100%
USD/CAD Oct 2024 - Jan 2025
0.00
Total Trades 45
Won Trades 0
Lost trades 45
Win Rate 0.00 %
Expected payoff -197.24
Gross Profit 0.00
Gross Loss -8875.82
Total Net Profit -8875.82
-100%
-50%
0%
50%
100%

Comments