This forum is in read-only mode now. You may discuss your questions on forums of MQL4.community and MQL5.community

Refreshing all quotes


Back to topics list  | 1 2
avatar
19
AndrewSchwartz 2005.06.06 11:06 
Do you mean MtGetSecurities?

I tried MtGetSecurities. It returns a ConSecurity*. In the ConSecurity, the "spread" parameter is 0. I would expect it to return 3 or 4 or something larger than 0.

Thanks.
avatar
4464
Slawa 2005.06.06 11:33 
sorry. there is undocumented function. forgotten. sorry. add to mtapi.h

MT_API int MtGetSecurityInfo(const int handle,const char *symbol,ConSecurity *sbi);


add to MetaTraderAPI.h

typedef int          (*MtGetSecurityInfo_t)(const int handle,const char *symbol,ConSecurity *sbi);


and to the class CMetaTraderAPI

   MtGetSecurityInfo_t           MtGetSecurityInfo;
...
   int			       GetSecurityInfo(const char *symbol,ConSecurity *sbi);



also for last quotes try to use MtGetSymbol function

Back to topics list   | 1 2  
Download MetaTrader 5 (450 Kb, web installer) — a new terminal for financial markets