[ARCHIVE]Any rookie question, so as not to clutter up the forum. Professionals, don't pass it by. Can't go anywhere without you - 5. - page 179

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
Help me find an EA or a script, there must be one ready...
I need an EA to open a deal with a certain loss and profit at a certain time on the market. I do not need anything else from it...
Thank you in advance.
Any Expert Advisor does this in MetaEditor, and the corresponding scripts in MetaEditor!
if(Hour() >= xx) открыть;
Good day to you all!
I'm a newbie. This is my first time trying to put an idea into code in the tester.
The idea is simple - to open one order alternately up and down at opening price of each hourly candlestick.
I wrote a simple code .... But the problem is that the program sometimes opens more than 1 order at opening of one candlestick.
As it seems to me it happens when more than 1 tick comes in 1 second.
I tried to put in header of if( ) condition...
Only one order really opens.
But this variant does not suit me since the next day the given candle is not opened, since at the moment of opening of this candle
There is already a random number of orders in the trade.
I also tried to interrupt the execution of the OrderSend(Symbol(),OP_BUY,0.1,Price,3,SL,TP) with return; ..... did not help.
I would appreciate if you tell me how to make only 1 order is opened at any tick within 1 second.
int start()
{
double Price=Ask;
double SL=Price-300*Point;
double TP=Price+300*Point;
if( Hour()==10 && Minute()== 00 && Seconds()==00)
OrderSend(Symbol(),OP_BUY,0.1,Price,3,SL,TP);
}
Well, I don't know how, but the data should be saved.
Good day to you all!
I'm a newbie. This is my first time trying to put an idea into code in the tester.
The idea is simple - to open one order alternately up and down at opening price of each hourly candlestick.
I wrote a simple code .... But the problem is that the program sometimes opens more than 1 order at opening of one candlestick.
As it seems to me it happens when more than 1 tick comes in 1 second.
I tried to put in header of if( ) condition...
Only one order really opens.
But this variant does not suit me since the next day the given candle is not opened, since at the moment of opening of this candle
There is already a random number of orders in the trade.
I also tried to interrupt the execution of the OrderSend(Symbol(),OP_BUY,0.1,Price,3,SL,TP) with return; ..... did not help.
I would appreciate if you tell me how to make only 1 order is opened at any tick within 1 second.
int start()
{
double Price=Ask;
double SL=Price-300*Point;
double TP=Price+300*Point;
if( Hour()==10 && Minute()== 00 && Seconds()==00)
OrderSend(Symbol(),OP_BUY,0.1,Price,3,SL,TP);
}
solnce600:
I would be grateful if you tell me how to make it so that within 1 second, only 1 order is opened on any tick.