//+------------------------------------------------------------------+ //| TPSL-Insert.mq4 | //| | //| | //+------------------------------------------------------------------+ #property copyright "" #property link "" //---- input parameters extern double TakeProfitPips=35; extern double StopLossPips=100; int Faktor, Digt, cnt; double TPp, SLp; //+------------------------------------------------------------------+ //| expert initialization function | //+------------------------------------------------------------------+ int init(){} //+------------------------------------------------------------------+ //| expert deinitialization function | //+------------------------------------------------------------------+ int deinit(){} //+------------------------------------------------------------------+ //| expert start function | //+------------------------------------------------------------------+ int start() { if(Close[0]>10) {Faktor=1000; Digt=3;} else if(Close[0]<10) {Faktor=100000; Digt=5;} if(OrdersTotal()!=0) { for(cnt=0; cnt