Download MetaTrader 5
To add comments, please log in or register
Find out the latest MQL5.community news!
vopot
21
vopot 2015.05.19 13:00 

Hi

I use example from MQL4 help file in my code (the same as https://www.mql5.com/en/docs/constants/structures/mqltick). It prints correct time, correct bid, correct ask, but volume is always zero. I even tried to insert 10 sec delay so that there were several price changes between calling SymbolInfoTick, but still the same: volume=0. EURUSD, M1. Please help!!!

void OnTick()
  {
   MqlTick last_tick;
//---
   if(SymbolInfoTick(Symbol(),last_tick))
     {
      Print(last_tick.time,": Bid = ",last_tick.bid,
            " Ask = ",last_tick.ask,"  Volume = ",last_tick.volume);
     }
   else Print("SymbolInfoTick() failed, error = ",GetLastError());
//---
  }
 
Documentation on MQL5: Standard Constants, Enumerations and Structures / Data Structures / Structure for Current Prices
Documentation on MQL5: Standard Constants, Enumerations and Structures / Data Structures / Structure for Current Prices
  • www.mql5.com
Standard Constants, Enumerations and Structures / Data Structures / Structure for Current Prices - Reference on algorithmic/automated trading language for MetaTrader 5
Alain Verleyen
Moderator
28702
Alain Verleyen 2015.05.21 14:04  
vopot:

Hi

I use example from MQL4 help file in my code (the same as https://www.mql5.com/en/docs/constants/structures/mqltick). It prints correct time, correct bid, correct ask, but volume is always zero. I even tried to insert 10 sec delay so that there were several price changes between calling SymbolInfoTick, but still the same: volume=0. EURUSD, M1. Please help!!!

This is information is only available if the broker provide it, and afaik not available with MT4.
yalewang
577
yalewang 2016.03.06 08:23  
which broker offer the full data ,please ?
Vasyl Nosal
18226
Vasyl Nosal 2016.03.06 10:27  
Alain Verleyen:
This is information is only available if the broker provide it, and afaik not available with MT4.

Why tick volume not avalible in MT4?

Why broker volumes not avalible in mt4? 

yalewang
577
yalewang 2016.03.06 12:37  
does the terminal i download from MQL5.com offer all the data ,and are the data the same with other brokers ?
/
To add comments, please log in or register