//+------------------------------------------------------------------+ //| candlesample.mq4 | //| tanyaodora | //| http://tandora.blog.fc2.com/ | //+------------------------------------------------------------------+ #property copyright "tanyaodora" #property link "http://tandora.blog.fc2.com/" int magic = 5; extern double Orderlot=0.1; //+------------------------------------------------------------------+ //| expert initialization function | //+------------------------------------------------------------------+ int init() { //---- //---- return(0); } //+------------------------------------------------------------------+ //| expert deinitialization function | //+------------------------------------------------------------------+ int deinit() { //---- //---- return(0); } //+------------------------------------------------------------------+ //| expert start function | //+------------------------------------------------------------------+ int start() { //---- bool haspos=false; if(OrdersTotal()>0){ for(int i=0;i High[2]){ OrderSend(NULL,OP_BUY,Orderlot,Ask,0,0,0,magic); } }else{ if(High[3]>High[2] && High[2]>High[1]){ for(i=0;i