Download MetaTrader 5

Is there any way to find ( programatically ) that a given symbol is currency pair / commodity or a share ?

To add comments, please log in or register
Balachandran Chandrasekar
44128
Balachandran Chandrasekar  
Ii want to make a for loop, which searches all symbols in marketwatch and return only commodity / FOREX Pairs or Shares .
Alain Verleyen
Moderator
33504
Alain Verleyen  
chandra100:
Ii want to make a for loop, which searches all symbols in marketwatch and return only commodity / FOREX Pairs or Shares .
  SymbolInfoInteger(symbol, SYMBOL_TRADE_CALC_MODE);

See documentation.

Maxim Khrolenko
7873
Maxim Khrolenko  
chandra100:
Ii want to make a for loop, which searches all symbols in marketwatch and return only commodity / FOREX Pairs or Shares .
In the article MQL5 Cookbook: Multi-Currency Expert Advisor - Simple, Neat and Quick Approach read about custom GetSymbol() function.
To add comments, please log in or register