- there are no trading operations
- about ea help me please.
- EA not opening pending orders
Hi everyone..Sorry but i need help...i have ea which work very well on any pair like EURUSD,AUDUSD,EURJPY, but the problm is the same EA doesn't work on ETF, so i want to what going wrong exactly. Does ordersend for ETF different? Somebody help me
I can help you... You can post file....
THANK YOU BROTHER....
THIS IS ONE OF MY FUNCTION WITH MANY STRATEGIES.
AS YOU CAN SEE I HAVE TO SET THE PAIR IN THE PARAMETER. THIS WORKING VERY WELL WITH PAIR LIKE EURAUD,EURJPY,...
BUT WHEN I SET ETF INTRUMENT, IT DOESN'T WORK.
I WONDER IF ETF ORDERSEND SETTING ARE DIFFERENT FROM THE OTHERS
THANK YOU
void OpenPositionAsset1()
{
EndTrade1();
if(StrToTime(StartTime_Asset1)<TimeCurrent()&&StrToTime(StartTime_Asset1)+500>TimeCurrent() && AllowOrder==true && Again1==true)
{
if(Strat1_Asset1==true && Strat2_Asset1==false && Strat3_Asset1==false && Strat4_Asset1==false && !PositionExcist(1234))
{
OrderSend(Asset1,OP_BUY,LotAsset1,Ask,3,Bid-SLCalcul1()*pips,Ask+TPCalcul1()*pips,NULL,1234,0,clrBlue);
AmountAsset1=((AccountEquity()/Numb_Asset)*Percen_Invest_Asset1)/100.0;
Again1=false;
}
if(Strat1_Asset1==false && Strat2_Asset1==true && Strat3_Asset1==false && Strat4_Asset1==false && !PositionExcist(1234))
{
OrderSend(Asset1,OP_SELL,LotAsset1,Bid,3,Ask+SLCalcul1()*pips,Bid-TPCalcul1()*pips,NULL,1234,0,clrRed);
AmountAsset1=((AccountEquity()/Numb_Asset)*Percen_Invest_Asset1)/100.0;
Again1=false;
}
if(Strat1_Asset1==false && Strat2_Asset1==false && Strat3_Asset1==true && Strat4_Asset1==false && !PositionExcist(1234))
{
if(iClose(Asset1,PERIOD_D1,1)>iOpen(Asset1,PERIOD_D1,1))
{
OrderSend(Asset1,OP_BUY,LotAsset1,Ask,3,Bid-SLCalcul1()*pips,Ask+TPCalcul1()*pips,NULL,1234,0,clrBlue);
AmountAsset1=((AccountEquity()/Numb_Asset)*Percen_Invest_Asset1)/100.0;
Again1=false;
}
if(iClose(Asset1,PERIOD_D1,1)<iOpen(Asset1,PERIOD_D1,1))
{
OrderSend(Asset1,OP_SELL,LotAsset1,Bid,3,Ask+SLCalcul1()*pips,Bid-TPCalcul1()*pips,NULL,1234,0,clrRed);
AmountAsset1=((AccountEquity()/Numb_Asset)*Percen_Invest_Asset1)/100.0;
Again1=false;
}
}
if(Strat1_Asset1==false && Strat2_Asset1==false && Strat3_Asset1==false && Strat4_Asset1==true && !PositionExcist(1234))
{
if(iClose(Asset1,PERIOD_D1,1)>iOpen(Asset1,PERIOD_D1,1))
{
OrderSend(Asset1,OP_SELL,LotAsset1,Bid,3,Ask+SLCalcul1()*pips,Bid-TPCalcul1()*pips,NULL,1234,0,clrRed);
AmountAsset1=((AccountEquity()/Numb_Asset)*Percen_Invest_Asset1)/100.0;
Again1=false;
}
if(iClose(Asset1,PERIOD_D1,1)<iOpen(Asset1,PERIOD_D1,1))
{
OrderSend(Asset1,OP_BUY,LotAsset1,Ask,3,Bid-SLCalcul1()*pips,Ask+TPCalcul1()*pips,NULL,1234,0,clrBlue);
AmountAsset1=((AccountEquity()/Numb_Asset)*Percen_Invest_Asset1)/100.0;
Again1=false;
}
}
}
}
Forum on trading, automated trading systems and testing trading strategies
When you post code please use the CODE button (Alt-S)!
Please do not make excessive use of capital letters when posting.It is considered shouting and very rude.
You are a developer in Freelance, so if this topic is concerning a freelance job that you are being paid for, you should at least state the fact.
I know that it is not obvious, but topics concerning MT4 and MQL4 have their own section.
In future please post in the correct section.
I will move your topic to the MQL4 and Metatrader 4 section.
Please do not make excessive use of capital letters when posting.It is considered shouting and very rude.
Thank you Keith
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use