//+——————————————————————+
//| Tian.mq4 |
//| Kristianto |
//| https://jual-baju-murah-meriah.blogspot.com |
//+——————————————————————+
#property copyright “Vajra”
#property link “Bukalapak.com/”
#property version “1.00”
#property strict
double para, nana, nani, pari, tari, dari, pani, nisa, nasi;
bool closeResult;
double Lots=0.01;
int MaxOrder=10;
int akunku=39031212;//+——————————————————————+
//| Expert initialization function |
//+——————————————————————+
int init()
{
//—
if(akunku!=AccountNumber())
{
Alert(“Akun anda belum terdaftar untuk pengguna EA ini!!!!”);
return(INIT_FAILED);
ExpertRemove();
}
return(0);//—
return(0);
}
//+——————————————————————+
//| Expert deinitialization function |
//+——————————————————————+
int deinit()
{
//—return(0);
}
//+——————————————————————+
//| Expert tick function |
//+——————————————————————+
int start()
{
if(IsExpertEnabled())
{//string broker = StringSubstr(AccountCompany(),0,2);
string broker = AccountCompany();
if(StringSubstr(broker,0,2)==”XM”)
{if(Symbol()!=”EURUSD”) //Pair WAJIB Micro
{if(Symbol()==”EURUSDmicro”) //Pair WAJIB EU
{//—
pari = Bid*100000;
tari = MathMod(pari,100);
pani = Ask*100000;
dari = MathMod(pani,100);
int totalorders = OrdersTotal();if(totalorders==0)
{
if(dari>9 && dari<=28){
for(int b=1;b<=MaxOrder;b++)
{
int ticket=OrderSend(Symbol(),OP_BUY,Lots,Ask,3,Ask-(dari+40)*0.00001,Ask-(dari-68)*0.00001);
}}
if(totalorders == 0 && tari>=72 && tari<91){for(int s=1;s<=MaxOrder;s++)
{
int ticket=OrderSend(Symbol(),OP_SELL,Lots,Bid,3,Bid-(tari-140)*0.00001,Bid-(tari-32)*0.00001);
}}
}else if(totalorders > 0)
{
if(OrderSelect(0, SELECT_BY_POS))
{
if(totalorders < 5)
{
if(OrderType() == OP_BUY && dari>25 && dari<=46){
for(int q=1;q<=5;q++)
{
int ticket=OrderSend(Symbol(),OP_BUY,Lots,Ask,3,Ask-(dari+40)*0.00001,0);
}}
if(OrderType() == OP_SELL && tari>=54 && tari<75){
for(int t=1;t<=5;t++)
{
int ticket=OrderSend(Symbol(),OP_SELL,Lots,Bid,3,Bid-(tari-140)*0.00001,0);
}}
}}
//MODIFY DAN CLOSE
for(int i=totalorders-1;i>=0;i–)
{
OrderSelect(i, SELECT_BY_POS);if(OrderSymbol()==Symbol())
{
para = OrderOpenPrice()*100000;
nana = MathMod(para,100);
nasi = MathMod(DoubleToStr(OrderTakeProfit()*100000,0),100);if(OrderType() == OP_BUY)
{
if(tari>54 && Bid>OrderOpenPrice()) {
closeResult = OrderClose(OrderTicket(), OrderLots(), Bid, 3);
RefreshRates();}if (tari<15 && nasi!=54) {OrderModify(OrderTicket(),OrderOpenPrice(),OrderStopLoss(),OrderOpenPrice()-(nana-54)*0.00001,0,Green);}
}else if(OrderType() == OP_SELL)
{
if(dari<46 && Ask<OrderOpenPrice()) {
closeResult = OrderClose(OrderTicket(), OrderLots(), Ask, 3);
RefreshRates();}if (dari>85 && nasi!=46) {OrderModify(OrderTicket(),OrderOpenPrice(),OrderStopLoss(),OrderOpenPrice()-(nana-46)*0.00001,0,Green);}
}}
}
}
Comment(“”);
} else {Comment(“EA ini Hanya dapat digunakan di PAIR EURUSDmicro\nSilahkan ganti pair Aktif ke EURUSDmicro”);}
} else {Comment(“Wajib Pair EurUsd MICRO Bos\nSilahkan ganti pair Aktif ke EURUSDmicro”);}
} else {Comment(broker,” bukan Broker yg direkemondasikan di Petunjuk ya bos\nSilahkan pindah broker”);}
} else {Comment(“Tekan Ctrl+E bos untuk mengkatifkan AutoTrading”);}
return(0);
}
//+——————————————————————+
相关资源
暂无评论...