Trading at Specific Hour in MT5

 

How to make EA trade at Specific Hour MT5?

i.e. 12pm to 10pm PST

Thank you!

 
  1. Check the current hour is ≥ 12 and < 22.
  2. All times are broker time. Do you really want to code broker time to GMT to PST? What about DST broker and PDT?