Orders Execution
0
Views
0
Downloads
0
Favorites
Profitability Reports
AUD/USD
Oct 2024 - Jan 2025
5.00 %
Total Trades
2191
Won Trades
0
Lost trades
0
Win Rate
0.00 %
Expected payoff
-4.34
Gross Profit
531.30
Gross Loss
-10032.70
Total Net Profit
-9501.40
-100%
-50%
0%
50%
100%
GBP/USD
Oct 2024 - Jan 2025
6.00 %
Total Trades
2206
Won Trades
1199
Lost trades
1007
Win Rate
0.54 %
Expected payoff
-4.31
Gross Profit
605.10
Gross Loss
-10106.40
Total Net Profit
-9501.30
-100%
-50%
0%
50%
100%
Lucky_code
//+------------------------------------------------------------------+
//| |
//| |
//| |
//+------------------------------------------------------------------+
double a, b;
bool first=true;
extern int Shift = 3;
extern int Limit = 18;
//----------------------------------------------------------------------------
int start()
{
if (first)
{
a=Ask;
b=Bid;
first=false;
return(0);
}
if (Ask-a>=Shift*Point)
{
OrderSend(Symbol(),OP_SELL,GetLots(),Bid,3,0,0,"",0,0,CLR_NONE);
}
if (b-Bid>=Shift*Point)
{
OrderSend(Symbol(),OP_BUY,GetLots(),Ask,3,0,0,"",0,0,CLR_NONE);
}
a=Ask;
b=Bid;
CloseAll();
return(0);}
//-----------------------------------------------------------------------------
void CloseAll()
{
for (int cnt = OrdersTotal()-1 ; cnt >= 0; cnt--)
{
OrderSelect(cnt,SELECT_BY_POS,MODE_TRADES);
if (OrderSymbol() == Symbol())
{
if ((OrderProfit()>0))
{
if(OrderType()==OP_BUY) OrderClose(OrderTicket(),OrderLots(),Bid,3,CLR_NONE);
if(OrderType()==OP_SELL) OrderClose(OrderTicket(),OrderLots(),Ask,3,CLR_NONE);
}
else
{
if((OrderType()==OP_BUY) && (((OrderOpenPrice()-Ask)/Point) > Limit))
OrderClose(OrderTicket(),OrderLots(),Bid,3,CLR_NONE);
if((OrderType()==OP_SELL) && (((Bid-OrderOpenPrice())/Point) > Limit))
OrderClose(OrderTicket(),OrderLots(),Ask,3,CLR_NONE);
}
}
}
}
//--------------------------------------------------------------------------
double GetLots()
{
return (NormalizeDouble(AccountFreeMargin()/10000,1));
}
//-------------------------------------------------------------------------
Comments
Markdown Formatting Guide
# H1
## H2
### H3
**bold text**
*italicized text*
[title](https://www.example.com)

`code`
```
code block
```
> blockquote
- Item 1
- Item 2
1. First item
2. Second item
---