How to make the Expert to trade only on a specific time? - page 2

 
Roozbeh Morad Nia: hour () means local time.
It means broker's server time.
 
Roozbeh Morad Nia:

Hi
Sorry
I understand what you mean now.
hour () means local time.
Here the system checks if the time is right, trades.
This time model works only on ea that is unique to us.

It is not local time, but that is beside the point.

I asked you to give me one example when your code returns true.

if(Hour()>=12 && Hour()<=10) 
   return(true);

To make it simpler for you, use an integer varable named X...

if(X>=12 && X<=10) 
   return(true);

Now give me a value for X where this will return true.

 
Roozbeh Morad Nia:
I don't know how to explain it to you.
Very simple.
I'm using this code to build simple ea's.
I wrote how to paste this code into an ea.
Paste these codes into an ea.

...

Forum on trading, automated trading systems and testing trading strategies


When you post code please use the CODE button (Alt-S)!

Use the CODE button


Reason: