v.bahremand:
Hi everyone,
I'm trying to prepare an expert which is able to do sell and buy in particular strategy. My program is working properly on Strategy
Tester but in real situations I'm getting several positions which are completely the same. My desired timeframe is H4 and
it means the expert can't open the position up to the next bar(4 hrs) but I have 4 or 5 buy or sell positions at the same time. Please help
me... TNX
show the code then
Do you really expect an answer? There are no mind readers here and our crystal balls are cracked. We can't see your broken code — we can only guess.
Cosmas Moses:
double ich= iIchimoku(Symbol(),PERIOD_CURRENT,9,26,52,MODE_KIJUNSEN,1);show the code then
bool close_flag_0;
if( (ich <= high1 ) && (ich >= low1 )) // connection between average line and a candle
{
if(iClose(Symbol(),PERIOD_CURRENT,1) > ich)
{
int buy = OrderSend(Symbol(),OP_BUY,lot,Ask,5,0,Ask+(Takeprofit*Point),"STRATEGY 1",4428,0,clrGreen);
}
//----------
else if(iClose(Symbol(),PERIOD_CURRENT,1) < ich)
{
int sell = OrderSend(Symbol(),OP_SELL,lot,Bid,5,Bid-(Stoploss*Point),0,"STRATEGY 1",4429,0,clrRed);
}
//

You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Hi everyone,
I'm trying to prepare an expert which is able to do sell and buy in particular strategy. My program is working properly on Strategy Tester but in real situations I'm getting several positions which are completely the same. My desired timeframe is H4 and it means the expert can't open the position up to the next bar(4 hrs) but I have 4 or 5 buy or sell positions at the same time. Please help me... TNX