Nieprzeczytany post
autor: Mighty Baz » 27 wrz 2010, 18:57
co sadzicie o takim skrypcie? Ktos testowal? Bo u mnie nie chodzi...moze zle skopiowalem code?
//| hedging M5 |
|
//+------------------------------------------------------------------+
#property copyright "Copyright © 2010 - Monu Ogbe"
#define MAGIC 1234
#define IDENT "mo_bidir"
extern double lots = 1;
extern double stop_loss = 76; // 8 pips (5-digit broker)
extern double take_profit = 750; // 75 pips
int last_bar = 0;
int start(){
if (last_bar == Bars) return(0);
last_bar = Bars;
if (OrdersTotal() == 0){
OrderSend(Symbol(), OP_BUY, lots ,Ask, 3, Ask - stop_loss * Point, Bid + take_profit * Point, IDENT, MAGIC, 0, Blue);
OrderSend(Symbol(), OP_SELL, lots ,Bid, 3, Bid + take_profit * Point, Ask - take_profit * Point, IDENT, MAGIC, 0, Red);
}
return(0);
}
}
//+------------------------------------------------------------------+
//| expert start function |
//+------------------------------------------------------------------+
int start()
{
//----
//----
return(0);
}
//+------------------------------------------------------------------+