Are you sure that symbol "EURUSD" is present iin "MarketWatch"
window?
//+------------------------------------------------------------------+ //| CheckMODE_TIME.mq4 | //| Copyright © 2007, MetaQuotes Software Corp. | //| https://www.metaquotes.net/ru/ | //+------------------------------------------------------------------+ #property copyright "Copyright © 2007, MetaQuotes Software Corp." #property link "https://www.metaquotes.net/ru/" //+------------------------------------------------------------------+ //| expert initialization function | //+------------------------------------------------------------------+ int init() { //---- //---- return(0); } //+------------------------------------------------------------------+ //| expert deinitialization function | //+------------------------------------------------------------------+ int deinit() { //---- //---- return(0); } //+------------------------------------------------------------------+ //| expert start function | //+------------------------------------------------------------------+ int start() { //---- RefreshRates(); datetime time1 = MarketInfo("EURUSD",MODE_TIME); Print(time1); //---- return(0); } //+------------------------------------------------------------------+
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
I would like to get the time of the last tick for a currency that is not the currency where I am running the EA.
According to the doc I make
RefreshRates();
datetime time1 = MarketInfo("EURUSD",MODE_TIME);
but time1 is always 0.
Any idea?
Thanks