Download MetaTrader 5

BAR & TICK TRADING

To add comments, please log in or register
EZENWA CHIAMAKA
15
EZENWA CHIAMAKA 2013.11.22 18:12 
Hello.
Is it possible to combine Bar check and Tick check in one EA? I mean one variable to be read from previous closed bar and another one to be read from tick while price changes before the close of the present bar.
Example
Var1 = iCCI(NULL,0,3,PRICE_CLOSE,1) ; // from previous day bar, which has closed
Var2 = iCCI(NULL,0,3,PRICE_CLOSE,0) // the indicator value of the present bar, before the bar closes.
If (Var1 > 0 &&Var2
Please help me on this.
Thanks.
Alain Verleyen
Moderator
31090
Alain Verleyen 2013.11.22 18:26  
EZECHIFOREX:
Hello.
Is it possible to combine Bar check and Tick check in one EA? I mean one variable to be read from previous closed bar and another one to be read from tick while price changes before the close of the present bar.
Example
Var1 = iCCI(NULL,0,3,PRICE_CLOSE,1) ; // from previous day bar, which has closed
Var2 = iCCI(NULL,0,3,PRICE_CLOSE,0) // the indicator value of the present bar, before the bar closes.
If (Var1 > 0 &&Var2
Please help me on this.
Thanks.
Help with what ? What's your issue ?
whroeder1
14737
whroeder1 2013.11.22 20:04  
EZECHIFOREX: Is it possible
What do you think the two lines of code you posted do?
EZENWA CHIAMAKA
15
EZENWA CHIAMAKA 2013.11.22 21:04  
To open trades! I mean when the present value of the indicator before the close of the bar is greater than the value of the indicator for the previous closed bar: Buy.
Keith Watford
Moderator
9642
Keith Watford 2013.11.23 00:49  
If (Var1 > 0 && Var2     // And Var2 what???
Tonny Obare
1025
Tonny Obare 2013.11.23 15:52  
Your post is exactly what you are asking for. Are you experiencing a bug from what you have posted above?
To add comments, please log in or register